mirror of
https://gitlab.silvrtree.co.uk/martind2000/nci.git
synced 2025-01-25 18:26:16 +00:00
use almond at production; include socketio and dataio clients to the build
This commit is contained in:
parent
4366105cf8
commit
4d07e3c71e
@ -13,7 +13,8 @@
|
|||||||
"bootstrap": "3.3.4",
|
"bootstrap": "3.3.4",
|
||||||
"font-awesome": "4.3.0",
|
"font-awesome": "4.3.0",
|
||||||
"react-router": "0.13.3",
|
"react-router": "0.13.3",
|
||||||
"ansi_up": "1.2.1"
|
"ansi_up": "1.2.1",
|
||||||
|
"almond": "0.3.1"
|
||||||
},
|
},
|
||||||
"moduleType": [
|
"moduleType": [
|
||||||
"amd"
|
"amd"
|
||||||
|
@ -11,8 +11,9 @@
|
|||||||
"dev": "gulp",
|
"dev": "gulp",
|
||||||
"sync": "npm install && npm prune && bower install && bower prune",
|
"sync": "npm install && npm prune && bower install && bower prune",
|
||||||
"buildJs": "r.js -o static/js/requirejs/buid.js",
|
"buildJs": "r.js -o static/js/requirejs/buid.js",
|
||||||
|
"buildClean": "rm static/index.html",
|
||||||
"buildHtml": "jade views/index.jade --obj '{\"env\": \"production\"}' -o static/",
|
"buildHtml": "jade views/index.jade --obj '{\"env\": \"production\"}' -o static/",
|
||||||
"build": "npm run buildJs && npm run buildHtml"
|
"build": "npm run buildJs && npm run buildHtml && git checkout static/scripts/app.js"
|
||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -3,8 +3,11 @@
|
|||||||
mainConfigFile: 'development.js',
|
mainConfigFile: 'development.js',
|
||||||
baseUrl: '../',
|
baseUrl: '../',
|
||||||
paths: {
|
paths: {
|
||||||
socketio: 'empty:',
|
socketio: (
|
||||||
_dataio: 'empty:'
|
'../../node_modules/socket.io/node_modules/' +
|
||||||
|
'socket.io-client/socket.io'
|
||||||
|
),
|
||||||
|
_dataio: '../../node_modules/data.io/data.io',
|
||||||
},
|
},
|
||||||
name: 'app/app',
|
name: 'app/app',
|
||||||
preserveLicenseComments: false,
|
preserveLicenseComments: false,
|
||||||
|
@ -1,8 +1,4 @@
|
|||||||
|
|
||||||
require.config({
|
require.config({
|
||||||
baseUrl: '/scripts',
|
baseUrl: '/scripts'
|
||||||
paths: {
|
|
||||||
socketio: '/socket.io/socket.io',
|
|
||||||
_dataio: '/data.io',
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
@ -5,8 +5,11 @@ html
|
|||||||
|
|
||||||
link(href="/css/index.css", rel="stylesheet", type="text/css")
|
link(href="/css/index.css", rel="stylesheet", type="text/css")
|
||||||
|
|
||||||
script
|
if env === 'development'
|
||||||
include ../static/js/libs/requirejs/require.js
|
script(type="text/javascript", src="/js/libs/requirejs/require.js")
|
||||||
|
else
|
||||||
|
script
|
||||||
|
include ../static/js/libs/almond/almond.js
|
||||||
|
|
||||||
if env === 'development'
|
if env === 'development'
|
||||||
script
|
script
|
||||||
|
Loading…
Reference in New Issue
Block a user