Alex Mikhalev
8 years ago
7 changed files with 53 additions and 9 deletions
@ -1,3 +1,4 @@
@@ -1,3 +1,4 @@
|
||||
/node_modules |
||||
npm-debug* |
||||
/build |
||||
/dist |
@ -0,0 +1,12 @@
@@ -0,0 +1,12 @@
|
||||
<!DOCTYPE html> |
||||
<html lang="en"> |
||||
<head> |
||||
<meta charset="UTF-8"> |
||||
<title>Sprinklers3</title> |
||||
</head> |
||||
<body> |
||||
<div id="app"></div> |
||||
|
||||
<script src="/static/app.js"></script> |
||||
</body> |
||||
</html> |
@ -0,0 +1,32 @@
@@ -0,0 +1,32 @@
|
||||
const path = require("path"); |
||||
const webpack = require("webpack"); |
||||
const HtmlWebpackPlugin = require("html-webpack-plugin"); |
||||
|
||||
module.exports = { |
||||
entry: [ |
||||
"./app/script/index.tsx" |
||||
], |
||||
devtool: "none", |
||||
output: { |
||||
path: path.resolve(__dirname, "dist"), |
||||
filename: "bundle.js" |
||||
}, |
||||
resolve: { |
||||
extensions: [".ts", ".tsx", ".js"], |
||||
alias: { |
||||
app: path.resolve("./app") |
||||
} |
||||
}, |
||||
module: { |
||||
rules: [ |
||||
{ test: /\.tsx?$/, loader: "awesome-typescript-loader" }, |
||||
{ test: /\.css$/, loader: "style-loader!css-loader" }, |
||||
{ test: /\.(ttf|eot|svg|woff(2)?|png|jpg)(\?[a-z0-9=&.]+)?$/, loader: "file-loader" } |
||||
] |
||||
}, |
||||
plugins: [ |
||||
new HtmlWebpackPlugin({ |
||||
template: "./app/index.html" |
||||
}) |
||||
] |
||||
}; |
Loading…
Reference in new issue