octokit / octokit.js

The all-batteries-included GitHub SDK for Browsers, Node.js, and Deno.
MIT License
6.93k stars 1.01k forks source link

[BUG]: Unable to import from Skypack CDN #2494

Closed brunojuliao closed 1 year ago

brunojuliao commented 1 year ago

What happened?

I use the octokit to authenticate my users and then retrieve files from a repo. It was working up to Saturday. Now I am getting the error below:

[Package Error] "@octokit/core@v5.0.0" could not be built. (Imported by "@octokit/rest"). [1/5] Verifying package is valid… [2/5] Installing dependencies from npm… [3/5] Building package using esinstall… Running esinstall... Failed to load node_modules/@octokit/core/dist-web/index.js Unexpected token (13:9) in @octokit/core/dist-web/index.js Install failed. Install failed.

Versions

Octokit.js v.19

import { Octokit } from "https://cdn.skypack.dev/@octokit/rest";

Relevant log output

[Package Error] "@octokit/core@v5.0.0" could not be built. (Imported by "@octokit/rest").
[1/5] Verifying package is valid…
[2/5] Installing dependencies from npm…
[3/5] Building package using esinstall…
Running esinstall...
Failed to load node_modules/@octokit/core/dist-web/index.js
  Unexpected token (13:9) in @octokit/core/dist-web/index.js
Install failed.
Install failed.

Code of Conduct

wolfy1339 commented 1 year ago

We don't recommend users use Skypack as it's not maintained anymore, and we use features that are too new for it to handle.

Instead we recommend people use ESM.sh