Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

232
Views
Vue-cli webpack dev server doesnt ignore selected files

I`m trying to ignore all *.html files so that webpack devserver wont reload when the files changes.

My config looks like this

const path = require('path');

module.exports = {
    pages:
    {
        index: 
        {
            entry: 'src/main.js',
            template: 'public/Index.html'
        }
    },
    outputDir: "wwwroot",
    filenameHashing: true,
    configureWebpack: 
    {
        devServer: {
            static: {
                directory: path.join(__dirname, 'public'),
                watch: 
                {
                    ignored: '*.html',
                    usePolling: false,
                }
            },
        },
        watchOptions: 
        {
            aggregateTimeout: 3000,
            ignored: /.*\.html/
        }
    }
}

I`m using @vue/cli-service: 5.0.4 which uses webpack 5. And it doesnt work, when I change html file webpack dev-server still reloads page. How I can make it work so changing html pages will not reload page?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Type regex expression in devServer.static.watch.ignored instead string

ignored: /.*\.html/
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!