systemjs最小系统加载工具
systemjs 是一个最小系统加载工具,用来创建插件来处理可替代的场景加载过程,包括加载 CSS 场景和图片,主要运行在浏览器和 NodeJS 中。它是 ES6 浏览器加载程序的的扩展,将应用在本地浏览器中。通常创建的插件名称是模块本身,要是没有特意指定用途,则默认插件名是模块的扩展名称。
通常它支持创建的插件种类有:
CSS
System.import('my/file.css!')
Image
System.import('some/image.png!image')
JSON
System.import('some/data.json!').then(function(json){})
Markdown
System.import('app/some/project/README.md!').then(function(html) {})
Text
System.import('some/text.txt!text').then(function(text) {})
WebFont
System.import('google Port Lligat Slab, Droid Sans !font')
示例:
System.formats = ['amd', 'cjs', 'myformat', 'global']; System.format.myformat = { detect: function(source, load) { if (!source.match(formatRegEx)) return false; // return the array of dependencies return getDeps(source); }, execute: function(load, depMap, global, execute) { // provide any globals global.myFormatGlobal = function(dep) { return depMap[dep]; } // alter the source before execution load.source = '(function() {' + load.source + '}();'; // execute source code execute(); // clean up any globals delete global.myFormatGlobal; // return the defined module object return global.module; } }
评论
LABjsJS加载工具
LABjs是一个很小的JavaScript工具,用来根据需要加载JavaScript文件,通过使用该工具可以提升页面的性能,避免加载不需用到的JavaScript文件,示例代码:$LAB.script
LABjsJS加载工具
0
FlappyBoardCH32V203G6 的最小系统板
CH32V203G6 的最小系统板,目标是极简、易用、低成本。3D渲染图许可证CERN-OHL-PE
FlappyBoardCH32V203G6 的最小系统板
0
phpdotenv环境变量加载工具
phpdotenv能自动加载从.env到getenv(),$_ENV和$_SERVER的环境变量,是基于原始的Ruby版本的dotenv。无需在Apache或Nginx中编辑虚拟主机不向php_val
phpdotenv环境变量加载工具
0
FlappyBoardCH32V203G6 的最小系统板
CH32V203G6的最小系统板,目标是极简、易用、低成本。3D渲染图许可证CERN-OHL-PEDAKiCad6.0.6使用方法下载程序推荐使用WCHISPTool的USB下载功能,简单易用。当然串
FlappyBoardCH32V203G6 的最小系统板
0
最小物联网系统开源IOT
文档一步步搭建物联网系统HTTPvsCoAP现有的这个版本是HTTP版,目前的CoAP版正在开发中,欢迎加入。https://github.com/phodal/iot-coapMinimumInte
最小物联网系统开源IOT
0