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

Mocha as a dependency #132

Open
nucliweb opened this issue Mar 15, 2022 · 3 comments
Open

Mocha as a dependency #132

nucliweb opened this issue Mar 15, 2022 · 3 comments

Comments

@nucliweb
Copy link

Hello,

I see that the mocha package is as a dependency and I think that is a devDependency, right?

@cramforce
Copy link
Collaborator

This template does run the tests after every build to ensure the build is good.

@nucliweb
Copy link
Author

Ok, but the tests run in dev or deploy mode. We don't need mocha in the production bundle, so if we move as a devDependency the mocha is available to run in build time because is installed too in the install process.

I know, if we don't import mocha in the code, mocha isn't part of the bundle but is a best practice to add as a dependencies only the packages needed to use in production or if the package is a tool or library.

@cramforce
Copy link
Collaborator

Nothing from package.json is currently bundled. I see the case of moving 100% of deps into devDepencencies. Feel free to send a PR.

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

2 participants