Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detect when jsDelivr is unable to bundle a package #1664

Open
mbostock opened this issue Sep 14, 2024 · 0 comments
Open

Detect when jsDelivr is unable to bundle a package #1664

mbostock opened this issue Sep 14, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@mbostock
Copy link
Member

When jsDelivr fails to bundle a package, it appears to succeed, but the code is replaced with:

/**
 * Failed to bundle using Rollup v2.79.1: the file imports a not supported node.js built-in module "node:perf_hooks".
 * If you believe this to be an issue with jsDelivr, and not with the package itself, please open an issue at https://github.com/jsdelivr/jsdelivr
 */

 throw new Error('Failed to bundle using Rollup v2.79.1: the file imports a not supported node.js built-in module "node:perf_hooks". If you believe this to be an issue with jsDelivr, and not with the package itself, please open an issue at https://github.com/jsdelivr/jsdelivr');

Example: https://cdn.jsdelivr.net/npm/happy-dom/+esm

We should detect this error and abort earlier so that it’s easier to tell what went wrong. Related #956.

@mbostock mbostock added the enhancement New feature or request label Sep 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant