Webpack watch not working on Webstorm on Windows?

后端 未结 3 1263
迷失自我
迷失自我 2021-01-30 00:43

So basically I have a project using Webpack, if I build using Webpack -w, editing the file with another editor will trigger the watch; however if I edit the file us

相关标签:
3条回答
  • 2021-01-30 01:30

    Also make sure you use Node's path construction instead of slashes. Example:

    entry: {
         'MyPackage': path.join(__dirname, 'modules', 'PkgEntry.js'),
    ...
    

    instead of:

    entry: {
         'MyPackage': '\\modules\\PkgEntry.js'),
    ...
    
    0 讨论(0)
  • 2021-01-30 01:31

    Had the same issue today. And accepted answer didn't help me.

    Check this page https://confluence.jetbrains.com/display/IDEADEV/Inotify+Watches+Limit and try to increase your Inotify Watches Limit. Helped me.

    0 讨论(0)
  • 2021-01-30 01:36

    Seems Webpack watch doesn't work if the file is not saved directly. Please try turning 'Safe write' option ( Settings | Appearance & Behavior | System Settings | Use "safe write" (save changes to temporary file first)) off.

    In 2020.* the option name is Back up files before saving

    0 讨论(0)
提交回复
热议问题