Giter VIP home page Giter VIP logo

nx-slow-storybook's Introduction

NX Slow Storybook

This repo demonstrates that the developer experience of using a Storybook configuraiton for a react library all generated through official @nrwl generators @nrwl/react:library and @nrwl/react:storybook-configuration is extremely slow.

Even with an incredibly simple monorepo set up with a single react component library that has a storybook configuration it takes 1-2 full seconds for HMR to kick in and the UI to update.

In our actual project at work where there are a few more libs and apps the hot reload can take 10-15 seconds which makes it completely unusable

Steps

  1. Install the dependencies by running yarn
  2. Run the storybook for the component library yarn nx storybook components and wait for it to become available
  3. Make a change inside components.tsx and observe that it takes a very long time for changes to be reflected in the UI

Notes

It feels like there is something going wrong with the setup here because I've seen in many other projects/setups that Storybook hot reloading should feel nearly instantaneous

Example output:

webpack built preview 629e33ca826bf35dc419 in 1504ms
webpack building...
webpack built preview e9f2d5d63a668308e3e0 in 1196ms
webpack building...
webpack built preview c4c4f47821c914339dbc in 1149ms

nx-slow-storybook's People

Contributors

wonderpanda avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.