Importing nested files causes dependency error
See original GitHub issueWhen importing a repository from github, I have two issues that have been troubling:
DevDependencies are not imported
When the package.json file is imported, it’s clearing everything except for the dependencies entry. This causes problems when importing a project that uses dev dependencies. My particular case is usually for a project that includes tests and requires react-test-renderer
as a devDependency. When imported the project complains that this dependency is missing. I don’t want this to be installed as a regular dependency.
Importing nested files causes dependency error
When importing from somewhere other than the root of a package, snack complains that the dependency is missing and prompts to install a dependency that includes the nested folder structure. If you do this, snack works, but the project fails locally because that package does not exist in npm (405 error).
For example:
Add react-native-vector-icons/MaterialIcons to package.json?
Add @react-native-community/async-storage/jest/async-storage-mock to package.json?
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (4 by maintainers)
Top GitHub Comments
@goatandsheep Supporting these kinds of situations where a working node-environment is needed goes beyond what Snack can offer. It’s good to know that there is a need for this though, but this will likely not be worked on in the foreseeable future.
@IjzerenHein I’m also having an issue with
devDependencies
in my snack. I’m just trying to create a demo app for a babel plugin I maintain, but it’s not working because thedevDependencies
aren’t loading properly.