system.js 替換 require.js

一、刪除requirejs,引入system.jsjavascript

<script src="~/lib/system.js/dist/system.js" type="text/javascript"></script>
<script>  
    // set our baseURL reference path
    System.config({
        baseURL: '/app'
    });
    System.import('startup.js');
</script>

二、java

window.define = System.amdDefine; window.require = window.requirejs = System.amdRequire;

 三、app

System.defaultJSExtensions = true;
相關文章
相關標籤/搜索