node.js - 为什么需要在 git repo 中删除 node_modules 文件夹?

标签 node.js git react-native node-modules

为什么需要忽略 git repo 中的node_modules?

其他将使用我的代码的用户,他们不需要我的node_modules文件夹吗?

最佳答案

node_module 太大,并且您已经有了 package.json,可以帮助通过 npm install/yarn install 命令安装 node_module 中的所有软件包。

保持小、干净和可维护,因此在 .gitignore 文件中添加 node_module

关于node.js - 为什么需要在 git repo 中删除 node_modules 文件夹?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48976391/

相关文章:

javascript - 如何在 Express/Nodejs 中捕获 404 错误?

git - 使用 SSH 用户名和密码将 Git 项目导入 Aptana

git - 为什么本地git显示的分支比服务器多

android - React Native 致命崩溃

android - React-Native 构建失败的应用程序 :mergeDebugAssets

html - Jade 中的音频输出

node.js - 如何使用工作线程实现网络自动化目的的 puppeteer 多线程

git - 将 (git) o​​rigin merge 到我当前的本地工作分支

javascript - 在 React Native 中使用 ScrollView 自定义分页

node.js - 将响应正文表达到缓冲区