Commit c1347e4e by David Kaltschmidt

WIP babel 7

parent 1f6df77a
{
"presets": [
[
"@babel/preset-env",
{
"targets": { "browsers": "last 3 versions" },
"useBuiltIns": "entry"
}
]
]
}
......@@ -10,6 +10,12 @@
"url": "http://github.com/grafana/grafana.git"
},
"devDependencies": {
"@babel/core": "^7.1.2",
"@babel/plugin-proposal-class-properties": "^7.1.0",
"@babel/plugin-syntax-dynamic-import": "^7.0.0",
"@babel/preset-env": "^7.1.0",
"@babel/preset-react": "^7.0.0",
"@babel/preset-typescript": "^7.1.0",
"@types/d3": "^4.10.1",
"@types/enzyme": "^3.1.13",
"@types/jest": "^23.3.2",
......@@ -21,10 +27,10 @@
"angular-mocks": "1.6.6",
"autoprefixer": "^6.4.0",
"axios": "^0.17.1",
"babel-core": "^6.26.0",
"babel-loader": "^7.1.4",
"babel-plugin-syntax-dynamic-import": "^6.18.0",
"babel-preset-es2015": "^6.24.1",
"babel-core": "^7.0.0-bridge",
"babel-jest": "^23.6.0",
"babel-loader": "^8.0.4",
"babel-plugin-angularjs-annotate": "^0.9.0",
"clean-webpack-plugin": "^0.1.19",
"css-loader": "^0.28.7",
"enzyme": "^3.6.0",
......@@ -127,13 +133,12 @@
},
"license": "Apache-2.0",
"dependencies": {
"@babel/polyfill": "^7.0.0",
"angular": "1.6.6",
"angular-bindonce": "0.3.1",
"angular-native-dragdrop": "1.2.2",
"angular-route": "1.6.6",
"angular-sanitize": "1.6.6",
"babel-jest": "^23.6.0",
"babel-polyfill": "^6.26.0",
"baron": "^3.0.3",
"brace": "^0.10.0",
"classnames": "^2.2.5",
......
import 'babel-polyfill';
import '@babel/polyfill';
import 'file-saver';
import 'lodash';
import 'jquery';
......
......@@ -2,7 +2,7 @@
// context.keys().forEach(context);
// module.exports = context;
import 'babel-polyfill';
import '@babel/polyfill';
import 'jquery';
import angular from 'angular';
import 'angular-mocks';
......
......@@ -47,7 +47,7 @@ module.exports = merge(common, {
module: {
rules: [
{
test: /\.tsx?$/,
test: /\.(j|t)sx?$/,
exclude: /node_modules/,
use: [{
loader: 'babel-loader',
......@@ -55,17 +55,23 @@ module.exports = merge(common, {
cacheDirectory: true,
babelrc: false,
plugins: [
'syntax-dynamic-import',
["@babel/plugin-proposal-class-properties", { loose: true }],
'angularjs-annotate',
'syntax-dynamic-import', // needed for `() => import()` in routes.ts
'react-hot-loader/babel'
]
}
},
],
presets: [
[
'@babel/preset-env',
{
loader: 'ts-loader',
options: {
transpileOnly: true,
experimentalWatchApi: true
},
targets: { browsers: 'last 3 versions' },
useBuiltIns: 'entry'
}
],
'@babel/preset-typescript',
'@babel/preset-react'
],
}
}],
},
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment