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

The CDN and Github source is different but same package version? #16

Open
subz390 opened this issue Jun 25, 2020 · 0 comments
Open

The CDN and Github source is different but same package version? #16

subz390 opened this issue Jun 25, 2020 · 0 comments

Comments

@subz390
Copy link

subz390 commented Jun 25, 2020

Hi I think there's a problem with the release.

  1. There's an issue with the yarnpkg CDN source that you've already fixed here in GitHub (three years ogo)
  2. The CDN and the GitHub package versions are the same, yet the source is different.
  3. Unrelated but confusing: GitHub says the latest releast is v0.2.0, yet CDN it's v0.3.0 and the package here in GitHub is v0.3.0?

Different Code - Same v0.3.0 package

yarn add --dev style-inject gets you this version
https://registry.yarnpkg.com/style-inject/-/style-inject-0.3.0.tgz#d21c477affec91811cc82355832a700d22bf8dd3

function styleInject(css, ref) {
  if ( ref === void 0 ) ref = {};
  var insertAt = ref.insertAt;

This has the issue of ref.insertAt can be an uncaught inexistant property, which I see you've fixed already in the current GitHub version.

yarn add --dev https://github.com/egoist/style-inject.git gets you also v0.3.0 but it's source is different;

export default function styleInject(css, { insertAt } = {}) {
  if (!css || typeof document === 'undefined') return

Summary

So basically yarn add --dev style-inject or yarn add --dev rollup-plugin-postcss gets the user an old version of the code which in my case failed Closure Compiler tests (I'll submit another issue about that shortly).

More

I also checked other repos and they have the same difference.
https://www.jsdelivr.com/package/npm/style-inject
https://registry.npmjs.org/style-inject/-/style-inject-0.3.0.tgz

@subz390 subz390 changed the title The NPM and Github source is different but same package version? The CDN and Github source is different but same package version? Jun 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant