mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-08-22 09:46:42 +02:00
Try babel
This commit is contained in:
@@ -75,6 +75,8 @@
|
|||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"async": "^2.3.0",
|
"async": "^2.3.0",
|
||||||
|
"babel-core": "^6.24.1",
|
||||||
|
"babel-loader": "^6.4.1",
|
||||||
"babel-preset-env": "^1.4.0",
|
"babel-preset-env": "^1.4.0",
|
||||||
"browserify": "~14.3.0",
|
"browserify": "~14.3.0",
|
||||||
"clone": "^2.1.1",
|
"clone": "^2.1.1",
|
||||||
@@ -114,7 +116,7 @@
|
|||||||
"hogan.js": "^3.0.2",
|
"hogan.js": "^3.0.2",
|
||||||
"jasmine": "2.5.3",
|
"jasmine": "2.5.3",
|
||||||
"jasmine-es6": "0.4.0",
|
"jasmine-es6": "0.4.0",
|
||||||
"jison": "zaach/jison",
|
"jison": "^0.4.17",
|
||||||
"jsdom": "^9.12.0",
|
"jsdom": "^9.12.0",
|
||||||
"jshint": "^2.9.4",
|
"jshint": "^2.9.4",
|
||||||
"jshint-stylish": "^2.2.1",
|
"jshint-stylish": "^2.2.1",
|
||||||
|
@@ -11,6 +11,25 @@ export const webConfig = () => {
|
|||||||
output: {
|
output: {
|
||||||
path: path.join(__dirname, './dist/'),
|
path: path.join(__dirname, './dist/'),
|
||||||
filename: '[name].js'
|
filename: '[name].js'
|
||||||
|
},
|
||||||
|
module: {
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
test: /\.js$/,
|
||||||
|
use: {
|
||||||
|
loader: 'babel-loader',
|
||||||
|
options: {
|
||||||
|
presets: [
|
||||||
|
['env', {
|
||||||
|
'targets': {
|
||||||
|
'browsers': ['last 3 versions']
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -26,6 +45,25 @@ export const nodeConfig = () => {
|
|||||||
path: path.join(__dirname, './dist/'),
|
path: path.join(__dirname, './dist/'),
|
||||||
filename: '[name].js',
|
filename: '[name].js',
|
||||||
libraryTarget: 'commonjs2'
|
libraryTarget: 'commonjs2'
|
||||||
|
},
|
||||||
|
module: {
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
test: /\.js$/,
|
||||||
|
use: {
|
||||||
|
loader: 'babel-loader',
|
||||||
|
options: {
|
||||||
|
presets: [
|
||||||
|
['env', {
|
||||||
|
'targets': {
|
||||||
|
'node': 4.2
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
36
yarn.lock
36
yarn.lock
@@ -579,6 +579,15 @@ babel-helpers@^6.24.1:
|
|||||||
babel-runtime "^6.22.0"
|
babel-runtime "^6.22.0"
|
||||||
babel-template "^6.24.1"
|
babel-template "^6.24.1"
|
||||||
|
|
||||||
|
babel-loader@^6.4.1:
|
||||||
|
version "6.4.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/babel-loader/-/babel-loader-6.4.1.tgz#0b34112d5b0748a8dcdbf51acf6f9bd42d50b8ca"
|
||||||
|
dependencies:
|
||||||
|
find-cache-dir "^0.1.1"
|
||||||
|
loader-utils "^0.2.16"
|
||||||
|
mkdirp "^0.5.1"
|
||||||
|
object-assign "^4.0.1"
|
||||||
|
|
||||||
babel-messages@^6.23.0:
|
babel-messages@^6.23.0:
|
||||||
version "6.23.0"
|
version "6.23.0"
|
||||||
resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e"
|
resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e"
|
||||||
@@ -1843,6 +1852,10 @@ commondir@0.0.1:
|
|||||||
version "0.0.1"
|
version "0.0.1"
|
||||||
resolved "https://registry.yarnpkg.com/commondir/-/commondir-0.0.1.tgz#89f00fdcd51b519c578733fec563e6a6da7f5be2"
|
resolved "https://registry.yarnpkg.com/commondir/-/commondir-0.0.1.tgz#89f00fdcd51b519c578733fec563e6a6da7f5be2"
|
||||||
|
|
||||||
|
commondir@^1.0.1:
|
||||||
|
version "1.0.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b"
|
||||||
|
|
||||||
component-bind@1.0.0:
|
component-bind@1.0.0:
|
||||||
version "1.0.0"
|
version "1.0.0"
|
||||||
resolved "https://registry.yarnpkg.com/component-bind/-/component-bind-1.0.0.tgz#00c608ab7dcd93897c0009651b1d3a8e1e73bbd1"
|
resolved "https://registry.yarnpkg.com/component-bind/-/component-bind-1.0.0.tgz#00c608ab7dcd93897c0009651b1d3a8e1e73bbd1"
|
||||||
@@ -3190,6 +3203,14 @@ finalhandler@~1.0.0:
|
|||||||
statuses "~1.3.1"
|
statuses "~1.3.1"
|
||||||
unpipe "~1.0.0"
|
unpipe "~1.0.0"
|
||||||
|
|
||||||
|
find-cache-dir@^0.1.1:
|
||||||
|
version "0.1.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-0.1.1.tgz#c8defae57c8a52a8a784f9e31c57c742e993a0b9"
|
||||||
|
dependencies:
|
||||||
|
commondir "^1.0.1"
|
||||||
|
mkdirp "^0.5.1"
|
||||||
|
pkg-dir "^1.0.0"
|
||||||
|
|
||||||
find-index@^0.1.1:
|
find-index@^0.1.1:
|
||||||
version "0.1.1"
|
version "0.1.1"
|
||||||
resolved "https://registry.yarnpkg.com/find-index/-/find-index-0.1.1.tgz#675d358b2ca3892d795a1ab47232f8b6e2e0dde4"
|
resolved "https://registry.yarnpkg.com/find-index/-/find-index-0.1.1.tgz#675d358b2ca3892d795a1ab47232f8b6e2e0dde4"
|
||||||
@@ -4751,20 +4772,7 @@ jison-lex@0.3.x:
|
|||||||
lex-parser "0.1.x"
|
lex-parser "0.1.x"
|
||||||
nomnom "1.5.2"
|
nomnom "1.5.2"
|
||||||
|
|
||||||
jison@zaach/jison:
|
jison@^0.4.17, jison@~0.4.15:
|
||||||
version "0.4.17"
|
|
||||||
resolved "https://codeload.github.com/zaach/jison/tar.gz/7653842e5120510b0b77484ac90d6c569cf146fd"
|
|
||||||
dependencies:
|
|
||||||
JSONSelect "0.4.0"
|
|
||||||
cjson "0.3.0"
|
|
||||||
ebnf-parser "0.1.10"
|
|
||||||
escodegen "1.3.x"
|
|
||||||
esprima "1.1.x"
|
|
||||||
jison-lex "0.3.x"
|
|
||||||
lex-parser "~0.1.3"
|
|
||||||
nomnom "1.5.2"
|
|
||||||
|
|
||||||
jison@~0.4.15:
|
|
||||||
version "0.4.17"
|
version "0.4.17"
|
||||||
resolved "https://registry.yarnpkg.com/jison/-/jison-0.4.17.tgz#bc12d46c5845e6fee89ccf35bd2a8cc73eba17f3"
|
resolved "https://registry.yarnpkg.com/jison/-/jison-0.4.17.tgz#bc12d46c5845e6fee89ccf35bd2a8cc73eba17f3"
|
||||||
dependencies:
|
dependencies:
|
||||||
|
Reference in New Issue
Block a user