Setup skeleton files for new front end build tool (Node, Webpack, React, Typescript)
This commit is contained in:
parent
8d39ed6d27
commit
9015b09026
9 changed files with 120 additions and 5 deletions
38
webpack.config.js
Normal file
38
webpack.config.js
Normal file
|
@ -0,0 +1,38 @@
|
|||
var webpack = require('webpack');
|
||||
var path = require("path");
|
||||
|
||||
var config = {
|
||||
/*
|
||||
* The entry point to the application
|
||||
*/
|
||||
entry: ["./static/js/app.tsx"],
|
||||
|
||||
/*
|
||||
* Output path of bundle
|
||||
*/
|
||||
output: {
|
||||
path: path.resolve(__dirname, "static/js/build"),
|
||||
filename: "bundle.js"
|
||||
},
|
||||
|
||||
/*
|
||||
* specify files to search for
|
||||
*/
|
||||
resolve: {
|
||||
extensions: ["", ".ts", ".tsx", ".js"]
|
||||
},
|
||||
module: {
|
||||
/*
|
||||
* Regex associated with the loader
|
||||
*/
|
||||
loaders: [
|
||||
{
|
||||
test: /\.tsx?$/,
|
||||
loader: "ts-loader",
|
||||
exclude: /node_modules/
|
||||
}
|
||||
]
|
||||
}
|
||||
};
|
||||
|
||||
module.exports = config;
|
Reference in a new issue