[英] Folder structure for a Node.js project
我注意到了那个节点.js项目通常包括以下文件夹:
/libs、/vendor、/support、/spec、/tests
这到底是什么意思?它们之间有什么不同,我应该在哪里包含引用的代码?
我注意到了那个节点.js项目通常包括以下文件夹:
/libs、/vendor、/support、/spec、/tests
这到底是什么意思?它们之间有什么不同,我应该在哪里包含引用的代码?
关于你提到的文件夹:
classes/functions/modules
NOTE: both 100 and 101 are deprecated since NPM introduced a clean package management. It's recommended to handle all 3rd-party dependencies using NPM and a package.json file
在构建一个相当大的应用程序时,我推荐以下额外的文件夹(尤其是如果您使用某种MVC-/ORM框架,比如express或mongoose):
/public
contains all static content (images, style-sheets, client-side JavaScript)我习惯了用这种方式组织我的项目,我觉得效果很好.
Update for CoffeeScript-based Express applications (using 100):
/assets/
contains all client-side assets that require compilation如何为一个网站实现这 2 个网址.即 www.administrator.sitename.com 和 www.sitename.com?
users.watch(在 gmail google api 中)如何收听通知?
使用中的端口代码:'EADDRINUSE',即使在 kill 命令之后
无法更新MongoDB中的文档:";伯森场';writeConcern.w';是错误的类型';数组'&引用;
当我们有“esnext”时,为什么我们需要“nodenext” typescript 编译器选项?
ChunkLoadError:加载块 node_modules_next_dist_client_dev_noop_js 失败
Electron 5.0.0“未捕获的 ReferenceError:未定义要求”
有什么方法可以修复 package-lock.json lockfileVersion 以便 npm 使用特定格式?
发生未处理的异常:作业(job)名称“..getProjectMetadata”不存在
错误消息:MongoError: bad auth Authentication failed through URI string
mac 中缺少对 /usr/local/lib/node_modules 的写访问权限