Merge pull request #260 from onip/browserify_fix

browserify build fix
This commit is contained in:
Jos de Jong 2016-01-21 19:49:55 +01:00
commit 419880dba8
3 changed files with 7 additions and 1 deletions

View File

@ -41,6 +41,11 @@ var compiler = webpack({
filename: NAME + '.js' filename: NAME + '.js'
}, },
plugins: [ bannerPlugin ], plugins: [ bannerPlugin ],
module: {
loaders: [
{ test: /\.json$/, loader: "json" }
]
},
cache: true cache: true
}); });

View File

@ -32,6 +32,7 @@
"gulp-minify-css": "^0.4.5", "gulp-minify-css": "^0.4.5",
"gulp-shell": "^0.3.0", "gulp-shell": "^0.3.0",
"gulp-util": "^3.0.3", "gulp-util": "^3.0.3",
"json-loader": "^0.5.4",
"mkdirp": "^0.5.0", "mkdirp": "^0.5.0",
"mocha": "^2.1.0", "mocha": "^2.1.0",
"uglify-js": "^2.4.16", "uglify-js": "^2.4.16",

View File

@ -1,6 +1,6 @@
var Ajv; var Ajv;
try { try {
Ajv = require('ajv/dist/ajv.bundle.js'); Ajv = require('ajv');
} }
catch (err) { catch (err) {
// no problem... when we need Ajv we will throw a neat exception // no problem... when we need Ajv we will throw a neat exception