Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changing template doesn't trigger build when watching #30

Closed
lukescott opened this issue May 5, 2015 · 2 comments
Closed

Changing template doesn't trigger build when watching #30

lukescott opened this issue May 5, 2015 · 2 comments

Comments

@lukescott
Copy link

Related to #5. I'm not sure if this is a regression, due to a change in webpack, or me just not knowing what I'm doing. I'm not able to get my template to rebuild or reload with either webpack -w or webpack-dev-server. I have to run webpack manually every time.

Config:

var HtmlWebpackPlugin = require("html-webpack-plugin");

module.exports = {
    entry: "./app/index.js",
    devtool: "source-map",
    output: {
        path: "./build",
        filename: "bundle.js",
        sourceMapFilename: "[file].map"
    },
    plugins: [
        new HtmlWebpackPlugin({
            filename: "index.html",
            template: "./app/index.html"
        })
    ],
    module: {
        loaders: [
            {
                test: /\.js$/,
                exclude: /node_modules/,
                loader: "babel-loader"
            }
        ]
    }
};

app/index.html:

<!DOCTYPE html>
<html>
<head>
    <script type="text/javascript" src="{%=o.htmlWebpackPlugin.files.chunks.main.entry%}"></script>
</head>
<body>
</body>
</html>
@jantimon
Copy link
Owner

#41 should fix this.

@lock
Copy link

lock bot commented Jun 1, 2018

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 1, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants