Merge branch 'master' into davkal/babel-7

This commit is contained in:
Torkel Ödegaard
2018-11-23 13:44:59 +01:00
426 changed files with 20781 additions and 3787 deletions

View File

@@ -16,7 +16,7 @@ module.exports = {
publicPath: "public/build/",
},
resolve: {
extensions: ['.ts', '.tsx', '.es6', '.js', '.json'],
extensions: ['.ts', '.tsx', '.es6', '.js', '.json', '.svg'],
alias: {
},
modules: [
@@ -47,7 +47,7 @@ module.exports = {
},
{
test: /\.html$/,
exclude: /index\.template.html/,
exclude: /(index|error)\-template\.html/,
use: [
{ loader: 'ngtemplate-loader?relativeTo=' + (path.resolve(__dirname, '../../public')) + '&prefix=public' },
{

View File

@@ -80,11 +80,16 @@ module.exports = merge(common, {
plugins: [
new CleanWebpackPlugin('../../public/build', { allowExternal: true }),
new MiniCssExtractPlugin({
filename: "grafana.[name].css"
filename: "grafana.[name].[hash].css"
}),
new HtmlWebpackPlugin({
filename: path.resolve(__dirname, '../../public/views/error.html'),
template: path.resolve(__dirname, '../../public/views/error-template.html'),
inject: false,
}),
new HtmlWebpackPlugin({
filename: path.resolve(__dirname, '../../public/views/index.html'),
template: path.resolve(__dirname, '../../public/views/index.template.html'),
template: path.resolve(__dirname, '../../public/views/index-template.html'),
inject: 'body',
chunks: ['manifest', 'vendor', 'app'],
}),

View File

@@ -93,7 +93,7 @@ module.exports = merge(common, {
new CleanWebpackPlugin('../public/build', { allowExternal: true }),
new HtmlWebpackPlugin({
filename: path.resolve(__dirname, '../../public/views/index.html'),
template: path.resolve(__dirname, '../../public/views/index.template.html'),
template: path.resolve(__dirname, '../../public/views/index-template.html'),
inject: 'body',
alwaysWriteToDisk: true
}),

View File

@@ -71,12 +71,17 @@ module.exports = merge(common, {
plugins: [
new MiniCssExtractPlugin({
filename: "grafana.[name].css"
filename: "grafana.[name].[hash].css"
}),
new ngAnnotatePlugin(),
new HtmlWebpackPlugin({
filename: path.resolve(__dirname, '../../public/views/error.html'),
template: path.resolve(__dirname, '../../public/views/error-template.html'),
inject: false,
}),
new HtmlWebpackPlugin({
filename: path.resolve(__dirname, '../../public/views/index.html'),
template: path.resolve(__dirname, '../../public/views/index.template.html'),
template: path.resolve(__dirname, '../../public/views/index-template.html'),
inject: 'body',
chunks: ['vendor', 'app'],
}),