DEV Community

loading...

The Quickest Way To Kickoff A React Typescript Storybook Project

hamatoyogi profile image Yoav Ganbar ・1 min read

Where do you start when you want to kick off a new TypeScript + React package or library? How do you add StoryBook into the mix?

This sounds like a daunting task if you haven't done it before, and even if you did, it's still kind of a pain in the butt.

Configuring a package is a myriad of decisions and tinkering with many files and configs of different tools.

What if I told you it doesn't have to be a pain at all? What if it's even a delightful experience? What if all you need to do is run one command? Wouldn't that blow your mind?!

https://i.postimg.cc/q7jZp5mj/mind-explode.gif

So here it is, the command you've been waiting for:

npx tsdx create my-new-project
Enter fullscreen mode Exit fullscreen mode

Follow the prompts and choose react-with-storybook.

That's it! Thanks for reading 😃

https://i.postimg.cc/zvM8fkjR/thanks.jpg

If you'd like a deeper dive and learn how to build a component library that uses Tailwind and Styled Components as well - check out my previous post: "How to Build A React TS Tailwind Design System"

Discussion (0)

Forem Open with the Forem app