mirror of
https://gitlab.silvrtree.co.uk/martind2000/frontexpress.git
synced 2025-01-25 19:16:17 +00:00
exposed frontexpress in the browser global context #2
This commit is contained in:
parent
ef16262c24
commit
474274c71f
3
.babelrc
3
.babelrc
@ -1,3 +1,4 @@
|
|||||||
{
|
{
|
||||||
"presets": ["es2015"]
|
"presets": ["es2015"],
|
||||||
|
"plugins": ["add-module-exports"]
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
index.js
|
||||||
frontexpress.min.js
|
frontexpress.min.js
|
||||||
test
|
test
|
||||||
coverage
|
coverage
|
2
frontexpress.min.js
vendored
2
frontexpress.min.js
vendored
File diff suppressed because one or more lines are too long
1
index.js
Normal file
1
index.js
Normal file
@ -0,0 +1 @@
|
|||||||
|
import frontexpress from 'expose?frontexpress!./lib/frontexpress.js';
|
@ -32,10 +32,13 @@
|
|||||||
"babel-eslint": "^6.1.2",
|
"babel-eslint": "^6.1.2",
|
||||||
"babel-istanbul": "^0.11.0",
|
"babel-istanbul": "^0.11.0",
|
||||||
"babel-loader": "^6.2.4",
|
"babel-loader": "^6.2.4",
|
||||||
|
"babel-plugin-add-module-exports": "^0.2.1",
|
||||||
"babel-preset-es2015": "^6.9.0",
|
"babel-preset-es2015": "^6.9.0",
|
||||||
|
"babel-register": "^6.14.0",
|
||||||
"chai": "^3.5.0",
|
"chai": "^3.5.0",
|
||||||
"eslint": "^3.1.0",
|
"eslint": "^3.1.0",
|
||||||
"eslint-loader": "^1.4.1",
|
"eslint-loader": "^1.4.1",
|
||||||
|
"expose-loader": "^0.7.1",
|
||||||
"istanbul": "^0.4.4",
|
"istanbul": "^0.4.4",
|
||||||
"mocha": "^2.5.3",
|
"mocha": "^2.5.3",
|
||||||
"rimraf": "^2.5.3",
|
"rimraf": "^2.5.3",
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
var webpack = require('webpack');
|
import webpack from 'webpack';
|
||||||
var path = require('path');
|
import path from 'path';
|
||||||
|
|
||||||
var frontend = {
|
export default {
|
||||||
entry: path.join(__dirname, 'lib','frontexpress.js'),
|
entry: path.join(__dirname, 'index.js'),
|
||||||
output: {
|
output: {
|
||||||
path: __dirname,
|
path: __dirname,
|
||||||
filename: 'frontexpress.min.js'
|
filename: 'frontexpress.min.js'
|
||||||
},
|
},
|
||||||
module: {
|
module: {
|
||||||
loaders: [
|
loaders: [
|
||||||
{ test: /\.js/, loader: 'babel-loader' },
|
{ test: /\.js/, loader: 'babel-loader' }
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
@ -18,5 +18,3 @@ var frontend = {
|
|||||||
new webpack.optimize.UglifyJsPlugin({ mangle: false, sourcemap: false }),
|
new webpack.optimize.UglifyJsPlugin({ mangle: false, sourcemap: false }),
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = [frontend];
|
|
Loading…
Reference in New Issue
Block a user