mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 17:59:23 -04:00
Merge pull request #4526 from spalger/es6
added babel/es6/jsx support to build system
This commit is contained in:
commit
ddfb3b0d53
4 changed files with 33 additions and 7 deletions
|
@ -54,9 +54,12 @@
|
|||
"angular-nvd3": "panda01/angular-nvd3#kibana",
|
||||
"angular-route": "1.2.28",
|
||||
"ansicolors": "^0.3.2",
|
||||
"auto-preload-rjscommon-deps-loader": "^1.0.3",
|
||||
"auto-preload-rjscommon-deps-loader": "^1.0.4",
|
||||
"autoprefixer": "^5.2.0",
|
||||
"autoprefixer-loader": "^2.0.0",
|
||||
"babel-core": "^5.8.19",
|
||||
"babel-loader": "^5.3.2",
|
||||
"babel-runtime": "^5.8.19",
|
||||
"bluebird": "^2.9.27",
|
||||
"boom": "^2.8.0",
|
||||
"bootstrap": "^3.3.5",
|
||||
|
@ -111,6 +114,7 @@
|
|||
"url-loader": "^0.5.6",
|
||||
"webpack": "^1.10.0",
|
||||
"webpack-directory-name-as-main": "^1.0.0",
|
||||
"whatwg-fetch": "^0.9.0",
|
||||
"zeroclipboard": "^2.2.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
@ -148,8 +152,7 @@
|
|||
"portscanner": "^1.0.0",
|
||||
"simple-git": "^1.3.0",
|
||||
"sinon": "^1.15.4",
|
||||
"source-map": "^0.4.4",
|
||||
"whatwg-fetch": "^0.9.0"
|
||||
"source-map": "^0.4.4"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=2"
|
||||
|
|
|
@ -72,7 +72,28 @@ class BaseOptimizer extends EventEmitter {
|
|||
{ test: /\.(html|tmpl)$/, loader: 'raw' },
|
||||
{ test: /\.png$/, loader: 'url?limit=10000&name=[path][name].[ext]' },
|
||||
{ test: /\.(woff|woff2|ttf|eot|svg|ico)(\?|$)/, loader: 'file?name=[path][name].[ext]' },
|
||||
{ test: /\/src\/(plugins|ui)\/.+\.js$/, loader: `auto-preload-rjscommon-deps${mapQ}` }
|
||||
{ test: /\/src\/(plugins|ui)\/.+\.js$/, loader: `auto-preload-rjscommon-deps${mapQ}` },
|
||||
{
|
||||
test: /\.js$/,
|
||||
exclude: /(node_modules|bower_components)/,
|
||||
loader: 'babel',
|
||||
query: {
|
||||
optional: ['runtime'],
|
||||
stage: 1,
|
||||
nonStandard: false
|
||||
}
|
||||
},
|
||||
{
|
||||
// explicitly require .jsx extension to support jsx
|
||||
test: /\.jsx$/,
|
||||
exclude: /(node_modules|bower_components)/,
|
||||
loader: 'babel',
|
||||
query: {
|
||||
optional: ['runtime'],
|
||||
stage: 1,
|
||||
nonStandard: true
|
||||
}
|
||||
}
|
||||
].concat(this.modules.loaders),
|
||||
noParse: this.modules.noParse,
|
||||
},
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
var _ = require('lodash');
|
||||
|
||||
var err = new Error();
|
||||
setByAssignment(err, 'john');
|
||||
try { setByAssignment(err, 'john'); } catch (e) {}
|
||||
|
||||
// err.stack is not always writeable, so we
|
||||
// do some detection for support and fallback to a
|
||||
|
|
|
@ -89,9 +89,11 @@ describe('ObjDefine Utility', function () {
|
|||
def.comp('name', val);
|
||||
var obj = def.create();
|
||||
|
||||
expect(function () {
|
||||
'use strict';
|
||||
|
||||
obj.name = notval; // UPDATE SHOULD BE IGNORED
|
||||
expect(obj).to.have.property('name', val);
|
||||
obj.name = notval;
|
||||
}).to.throwException();
|
||||
});
|
||||
|
||||
it('does not export the computed value to JSON', function () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue