question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Webpack Building Constantly

See original GitHub issue

Describe the bug Webpack constantly builds/rebuilds storybook on 6.2.0-rc.9

To Reproduce

  1. Install Storybook 6.2.0-rc.9.
  2. Start storybook

Expected behavior Should only rebuild when I update a file.

Code snippets

│   Storybook 6.2.0-rc.9 started                      
│   43 s for preview                                  
│                                                     
│    Local:            http://localhost:6006/         
│    On your network:  http://192.168.125.52:6006/    
│                                                     
webpack building...
webpack built preview 0f3021e86c6e6ac83984 in 20383ms
webpack building...
webpack built preview 0f3021e86c6e6ac83984 in 11474ms
webpack building...
webpack built preview 0f3021e86c6e6ac83984 in 5409ms
webpack building...
webpack built preview 0f3021e86c6e6ac83984 in 7213ms
webpack building...
webpack built preview 0f3021e86c6e6ac83984 in 4904ms
webpack building...
webpack built preview 0f3021e86c6e6ac83984 in 5029ms
webpack building...

System

Environment Info:

  System:
    OS: macOS 11.2.2
    CPU: (12) x64 Intel(R) Core(TM) i7-8850H CPU @ 2.60GHz
  Binaries:
    Node: 14.13.0 - ~/.nodenv/shims/node
    Yarn: 1.22.5 - /usr/local/bin/yarn
    npm: 6.14.8 - ~/.nodenv/shims/npm
  Browsers:
    Chrome: 89.0.4389.90
    Firefox: 86.0.1
    Safari: 14.0.3
  npmPackages:
    @storybook/addon-actions: ^6.2.0-rc.9 => 6.2.0-rc.9
    @storybook/addon-essentials: ^6.2.0-rc.9 => 6.2.0-rc.9
    @storybook/addon-links: ^6.2.0-rc.9 => 6.2.0-rc.9
    @storybook/preset-scss: ^1.0.3 => 1.0.3
    @storybook/react: ^6.2.0-rc.9 => 6.2.0-rc.9

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:20
  • Comments:31 (11 by maintainers)

github_iconTop GitHub Comments

55reactions
Sqrrlcommented, Mar 31, 2021

Having the same issue after upgrading to 6.2.1. Changing my main.js file to only load stories from the src/ directory fixes the issue.

Before (constantly re-building): stories: ['../**/*.mdx', '../**/*.stories.tsx']

After (no issues): stories: ['../src/**/*.mdx', '../src/**/*.stories.tsx']

I have no clue, what files were triggering the watcher.

7reactions
shilmancommented, Jun 1, 2021

closing this as fixed in 6.3

npx sb@next upgrade --prerelease
Read more comments on GitHub >

github_iconTop Results From Across the Web

Build Performance - webpack
This guide contains some useful tips for improving build/compilation performance. General. The following best practices should help, whether you're running ...
Read more >
Storybook webpack repeatedly rebuilding (hot reloading over ...
My CPU goes crazy and it drains my battery. After the build finishes, it immediately starts rebuilding. It's like it is hot reloading...
Read more >
Simple webpack plugin to identify the cause of repeated ...
This article shares a sample small plugin that provides the diagnostics info to identify the root cause for continuous rebuilds.
Read more >
How to boost the speed of your webpack build?
Use Speed Measure Plugin to debug webpack build time · Track your build time evolution to detect big evolution before merge · Follow...
Read more >
5 Strategies to Reduce Frontend Build Time with CI/CD
One of the features which make the Webpack so influential is its watcher that continuously rebuilds your application. You can use the same ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found