I cannot run octokit for GitHub in my application. It was working for long time but stopped. The error is
Uncaught SyntaxError: The requested module '/@octokit/webhooks-methods@^5.0.0?target=es2022' does not provide an export named 'verifyWithFallback' (at index.js:476:10)
I removed the things of the application to get the minimal application causing the error:
index.html
<script type="module">
import myFunc from "./myFunc.js";
</script>
myFunc.js
import {Octokit, App} from ";;
new Octokit({
auth: 'ghp_1234512345123451234512345'
});
const myFunc = ()=>"foo";
export default myFunc;
Before I did some things with git locally: clone, reset, push. Maybe that was the reason. I also changed the token to the new one, in GitHub and in my application. How to fix the error?
I cannot run octokit for GitHub in my application. It was working for long time but stopped. The error is
Uncaught SyntaxError: The requested module '/@octokit/webhooks-methods@^5.0.0?target=es2022' does not provide an export named 'verifyWithFallback' (at index.js:476:10)
I removed the things of the application to get the minimal application causing the error:
index.html
<script type="module">
import myFunc from "./myFunc.js";
</script>
myFunc.js
import {Octokit, App} from "https://esm.sh/octokit";
new Octokit({
auth: 'ghp_1234512345123451234512345'
});
const myFunc = ()=>"foo";
export default myFunc;
Before I did some things with git locally: clone, reset, push. Maybe that was the reason. I also changed the token to the new one, in GitHub and in my application. How to fix the error?
Share Improve this question edited Jan 31 at 20:01 trzczy asked Jan 31 at 19:54 trzczytrzczy 1,5012 gold badges21 silver badges46 bronze badges2 Answers
Reset to default 0This should be put
import {Octokit} from "https://esm.sh/@octokit/[email protected]";
Have same prblem here but we import octokit by cdn for a long time, don't know why it failed recently
import { Octokit } from 'https://esm.sh/octokit'