question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NPM missing source

See original GitHub issue

Documentation Is:

  • Missing or needed
  • Confusing
  • Not Sure?

Please Explain in Detail…

In npm packet version 2.8.0-rc.1 and 2.8.0 missing source code. There is only a folder dist. Is this what was meant?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
simonbrunelcommented, Apr 2, 2019

Alternatively (but not ideal), you could install Chart.js from GitHub directly:

 npm install -S https://github.com/chartjs/Chart.js/tarball/v2.8.0
// package.json
{
  "dependencies": {
    "chart.js": "https://github.com/chartjs/Chart.js/tarball/v2.8.0"
  }
}

So you will get the ‘/src’ folder and be able to use it at your own risk.

1reaction
simonbrunelcommented, Apr 2, 2019

@mojoaxel I understand your point and I’m sorry to read that we broke your integration.

I don’t think it’s a good idea to re-inject our sources in the npm package because you shouldn’t rely on it for many reasons. We should be able to rename/move/delete whatever file under /src, change the way we import/organize modules, add more rollup tricky build steps that would be complicated to integrate into your workflow (e.g. injecting the CSS - #6048), etc. without to worry about breaking existing projects that would target /src/**/* files. We don’t want to maintain backward compatibility on the /src files and that’s why it should not be in the npm package.

I would rather try to find a way to generate an ESM build that supports tree-shaking (#5179) so you could import exactly what you need.

Read more comments on GitHub >

github_iconTop Results From Across the Web

map sourcemap files missing from npm releases #2942 - GitHub
This error is occurring because we don't include the .map files within our npm releases. I'm a bit surprised though, since I don't...
Read more >
Installing an NPM module from github missing source files
I recently faced a problem with an npm module that I wanted to resolve myself and to do so I forked the original...
Read more >
source-map - npm
Generates and consumes source maps. Latest version: 0.7.4, last published: 7 months ago. Start using source-map in your project by running ...
Read more >
babel-plugin-source-map-support - npm package - Snyk
The npm package babel-plugin-source-map-support was scanned for known vulnerabilities and missing license, and no issues were found. Thus the package was deemed ...
Read more >
Emitting source maps - Learn TypeScript
Node.js and npm. You can download these from https:/​/​nodejs.​org/​en/​download. If you already have these ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found