UNPKG

mnr-table

Version:

Render table by using class decorator, includes several filter options.

71 lines (69 loc) 2.46 kB
// development config const { resolve } = require('path') const webpack = require('webpack') const HtmlWebpackPlugin = require('html-webpack-plugin') module.exports = { output: { publicPath: '/' }, mode: 'development', entry: [ 'react-hot-loader/patch', // activate HMR for React 'webpack-dev-server/client?http://localhost:8080', // bundle the client for webpack-dev-server and connect to the provided endpoint 'webpack/hot/only-dev-server', // bundle the client for hot reloading, only- means to only hot reload for successful updates './sample/index.tsx' // the entry point of our app ], devServer: { hot: true, // enable HMR on the server historyApiFallback: true }, devtool: 'cheap-module-eval-source-map', plugins: [ new HtmlWebpackPlugin({ template: './sample/index.html' }), new webpack.HotModuleReplacementPlugin(), // enable HMR globally new webpack.NamedModulesPlugin() // prints more readable module names in the browser console on HMR updates ], resolve: { extensions: ['.ts', '.tsx', '.js', '.jsx'] }, context: resolve(__dirname, '.'), module: { rules: [ { test: /\.js$/, use: ['babel-loader'], exclude: /node_modules/ }, { test: /\.tsx?$/, use: ['babel-loader', 'ts-loader'] }, { test: /\.css$/, use: ['style-loader', { loader: 'css-loader', options: { importLoaders: 1 } }] }, { test: /\.(scss|sass)$/, loaders: ['style-loader', { loader: 'css-loader', options: { importLoaders: 1 } }, 'sass-loader'] }, { test: /\.less$/, loaders: ['style-loader', { loader: 'css-loader', options: { importLoaders: 1 } }, 'less-loader'] }, { test: /\.(jpe?g|png|gif)$/i, loaders: [ 'file-loader?hash=sha512&digest=hex&name=img/[hash].[ext]', 'image-webpack-loader?bypassOnDebug&optipng.optimizationLevel=7&gifsicle.interlaced=false' ] }, { test: /\.svg$/i, use: ['@svgr/webpack'] } ] }, performance: { hints: false } }