Codesandbox-client: devDependencies in package.json doesn't seem to be processed

Created on 25 Jun 2018  路  7Comments  路  Source: codesandbox/codesandbox-client

馃悰 bug report: devDependencies not being fetched

Description of the problem

It seems that devDependencies aren't being fetched. Here's an example project that has "cross-fetch": "2.2.0", in devDependencies. If I move cross-fetch up to dependencies, it works just fine.

How has this issue affected you? What are you trying to accomplish?

This generally affects my testing process. I'd like to keep packages like fetch-mock in devDependencies instead of dependencies as I have to do at the moment.

Link to sandbox: Example Project

Your Environment

| Software | Name/Version|
| ---------------- | ---------- |
| 小odesandbox | latest (online) |
| Browser | Chrome Version 67.0.3396.87 (Official Build) (32-bit) |
| Operating System | ChromeOS |

馃帓 Bundler 馃 Improvement

Most helpful comment

Yeah, this is something we really need to add soon.

The biggest initial reason was to lower downloaded bundle size, as there are many projects with >20 dev dependencies and only using one dependency.

The way to fix it is to check during the initialization which devDependencies are used in the code and include those to the request. This means adding an extra pass during transpilation to the bundling. I will play a bit with this this month, in the meantime you can use a Server Sandbox to make it work.

All 7 comments

Yes, I'm facing the same issues

Yeah, this is something we really need to add soon.

The biggest initial reason was to lower downloaded bundle size, as there are many projects with >20 dev dependencies and only using one dependency.

The way to fix it is to check during the initialization which devDependencies are used in the code and include those to the request. This means adding an extra pass during transpilation to the bundling. I will play a bit with this this month, in the meantime you can use a Server Sandbox to make it work.

This issue is stale because it has been open many days with no activity. It will be closed soon unless the stale label is removed or a comment is made.

@CompuIves was this ever fixed? Or is this a wontfix for now?

For now, but I recently refactored our dependency installation with this in mind, so we're much closer to supporting this.

The biggest challenge is statically analyzing which dependencies are needed, and only installing those. Once we have that it will be both performant and consistent.

This issue has automatically been marked stale because there has been no activity in a while. Please leave a comment if the issue has not been resolved, or if it is not stale for any other reason. After 2 weeks, this issue will automatically be closed, unless a comment is made or the stale label is removed.

Bump

Was this page helpful?
0 / 5 - 0 ratings

Related issues

rdmurphy picture rdmurphy  路  20Comments

AlessandroAnnini picture AlessandroAnnini  路  25Comments

Telokis picture Telokis  路  24Comments

mescalito picture mescalito  路  65Comments

gautamarora picture gautamarora  路  50Comments