代码改变世界

CommonJS规范

  youxin  阅读(274)  评论(0编辑  收藏  举报
CommonJS是一种规范,NodeJS是这种规范的实现。CommonJS是一 个不断发展的规范,计划将要包括如下部分:
  • Modules
  • Binary strings and buffers
  • Charset encodings
  • Binary, buffered, and textual input and output (io) streams
  • System process arguments, environment, and streams
  • File system interface
  • Socket streams
  • Unit test assertions, running, and reporting
  • Web server gateway interface, JSGI
  • Local and remote packages and package management

具体每个子规范的定制进度请查看官方网站的说明:http://commonjs.org/specs/

CommonJS有很多实现,其中不乏很多大名鼎鼎的项目,比如 说:Apache的CouchDBnode.js等。但这些项目大 部分只实现了CommonJS的部分规范。具体的项目和实现部分参见官方网站的说明:http://commonjs.org/impl/
 
 
 
参考;
http://www.ruanyifeng.com/blog/2012/10/asynchronous_module_definition.html
 
 
编辑推荐:
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
阅读排行:
· 无需6万激活码!GitHub神秘组织3小时极速复刻Manus,手把手教你使用OpenManus搭建本
· Manus爆火,是硬核还是营销?
· 终于写完轮子一部分:tcp代理 了,记录一下
· 别再用vector<bool>了!Google高级工程师:这可能是STL最大的设计失误
· 单元测试从入门到精通
历史上的今天:
2014-03-03 Yii数据库
2014-03-03 Yii render 渲染
2014-03-03 yiic模块module使用
2013-03-03 jQuery关闭/显示侧边栏
2013-03-03 eval()中包含JSON格式的对象字面量时为何要加圆括号?
2013-03-03 JavaScript惰性载入函数
2013-03-03 javascript构造函数模式
点击右上角即可分享
微信分享提示