Storybook 7 Crash Course - React Typescript

  Рет қаралды 45,105

Marius Espejo

Marius Espejo

Күн бұрын

In this video I'll walk you through how to setup storybook for the first time as well as the fundamentals you need to know to create stories and develop ui or react JS / TS components in isolation.

Пікірлер: 106
@mariusespejo
@mariusespejo Жыл бұрын
Here's a follow up video covering interaction testing: kzbin.info/www/bejne/gpiQmYdmhJd5bac Let me know what you think! 😄
@md.lutfullahillabib
@md.lutfullahillabib Жыл бұрын
Can you make full tutorial from scratch including testing , build a full storybook like for a company with best coding? using vitejs, reactjs, javascript, tailwind-css. All latest versions. please? 🙏 & explaining everything.
@mariusespejo
@mariusespejo Жыл бұрын
@md.lutfullahillabib the fundamentals are all here, and the testing follow up is linked above, I don’t really see what else there would be to cover. Creating a “full” storybook would just be reiterating the same patterns
@rajatguptanarwana
@rajatguptanarwana 6 ай бұрын
Please share github repo link.
@mariusespejo
@mariusespejo 6 ай бұрын
@rajatguptanarwana it’s not really worth cloning, there’s very little code written. I suggest running the storybook init in your own project, it will come with much better examples to play around with.
@yajirushik2871
@yajirushik2871 5 ай бұрын
Personally this one video clearly introduces Storybook for me, even if it's outdated version, works perfectly. Thank You!
@ChrisHowardG
@ChrisHowardG 5 ай бұрын
Really awesome overview! Much better than some of the "Storybook in 10 min" videos I've seen. Thanks!
@mariusespejo
@mariusespejo 5 ай бұрын
Thank you!
@jacquitratongamanahaja979
@jacquitratongamanahaja979 Жыл бұрын
You are amazing Marius Espejo. The content and your explanation are very clear. It is very easy to follow along and understand everything. I can't wait to see the next video.
@mariusespejo
@mariusespejo Жыл бұрын
Thank you Jacquit!
@joicyjoy9658
@joicyjoy9658 10 ай бұрын
Awesome ....I have got clear idea about Storybook. I am usually a fan of WebDevSimplified you tube channel. But your channel is something I have recently explored. I could say you have nailed it by vivid explanation.
@mariusespejo
@mariusespejo 10 ай бұрын
Thank you! Glad you are enjoying the channel
@rrenildopereiraa
@rrenildopereiraa 8 күн бұрын
Woah, super useful!!! This is a gem, TYSM 🙏🏽
@filiptaticek1381
@filiptaticek1381 Жыл бұрын
Great video! I appreciate that it is very up to date, and you explained all the things clearly.
@waseemmn2007
@waseemmn2007 4 ай бұрын
Good video, simple and to the point for a quick overview of Storybook. keep it up 👏
@mariusespejo
@mariusespejo 4 ай бұрын
Thanks man!
@kranthikumar5215
@kranthikumar5215 7 ай бұрын
The way you are explaining is awesome.....rocking star.God bless you ma n❤
@mariusespejo
@mariusespejo 7 ай бұрын
Hey! Thank you so much 🙏
@dobingify3130
@dobingify3130 Жыл бұрын
You're teaching is very clear and straightforward. I highly recommend this!
@mariusespejo
@mariusespejo Жыл бұрын
Thank you 🙏
@rakeshkharvi4145
@rakeshkharvi4145 6 ай бұрын
Wow!, great video. very simple and elagant. beatifully expalined
@user-zw1pz2pj3p
@user-zw1pz2pj3p Жыл бұрын
Really do like the way you explain! Liked other videos too! Keep up the good work!
@user-zw1pz2pj3p
@user-zw1pz2pj3p Жыл бұрын
Do you recommend this video too? kzbin.info/www/bejne/p4TOeYWMgcidbLc
@rajkiranchaudhary8769
@rajkiranchaudhary8769 4 ай бұрын
Nice crash course. Thank you for making this video
@mariusespejo
@mariusespejo 4 ай бұрын
Totally, thanks for the comment!
@alexandrdermenji2428
@alexandrdermenji2428 Жыл бұрын
Nice to see video about testing with storybook
@AshlyLaMarr
@AshlyLaMarr 4 ай бұрын
Great job!
@mariusespejo
@mariusespejo 4 ай бұрын
Thank you! 🙌
@f0j1
@f0j1 Жыл бұрын
OMG Thank you so much! There was not a good documentation about Storybook 7. Cheers from 🇨🇱 Chile! :)
@jacquitratongamanahaja979
@jacquitratongamanahaja979 Жыл бұрын
It would be really nice if you can cover the visual test and interaction test in the next video.
@mariusespejo
@mariusespejo Жыл бұрын
posted! kzbin.info/www/bejne/gpiQmYdmhJd5bac
@fadliblight2822
@fadliblight2822 Жыл бұрын
Thankyou I quickly learn a lot from this video bro
@ifedayoagboola2763
@ifedayoagboola2763 Жыл бұрын
A very big thanks for this. You're the best!
@joeshepherd6590
@joeshepherd6590 Жыл бұрын
Great intro. Thank you!
@ahsanabrar880
@ahsanabrar880 8 ай бұрын
Good video quality, thanks
@doomnationalist
@doomnationalist 9 ай бұрын
This was really helpful, thank you!
@veritatas678
@veritatas678 Жыл бұрын
Cool video. I am interested in the visual testing.
@mariusespejo
@mariusespejo Жыл бұрын
posted! kzbin.info/www/bejne/gpiQmYdmhJd5bac
@DanEMO592
@DanEMO592 Жыл бұрын
Amazing! Thank you so much!!! :D
@user-bd3cr8lc5l
@user-bd3cr8lc5l Ай бұрын
thank you very much)))
@mariusespejo
@mariusespejo Ай бұрын
You’re welcome!
@loribryant4999
@loribryant4999 3 ай бұрын
I dont like the sound of your voice man, but your are really freaking good
@dweebycat9929
@dweebycat9929 Жыл бұрын
Amazing tutorial, thank you!
@mariusespejo
@mariusespejo Жыл бұрын
You’re welcome!
@someoneelse1952
@someoneelse1952 Жыл бұрын
Dude, did you go to css school or something? You are very fast and fluent. Thanks for the video. Very useful. I may have to use this tool for a while to determine what value this will add to my work flow & whether the benefits outweigh the cons.
@mariusespejo
@mariusespejo Жыл бұрын
Nah I play around with CSS until it looks right just like most people haha. As for the “cons” of storybook it’s really mostly the added code to write stories, but it’s up to you how much you utilize it. In my mind a lot of the benefits definitely outweighs a little extra code but definitely it also depends on your workflow
@amirhossein570
@amirhossein570 Жыл бұрын
Good video
@user-zh6hj7ng6s
@user-zh6hj7ng6s 8 ай бұрын
Hello, I'm new to Storybook, and I found this video very instructive. Could you share an example of how to use React Context API with Storybook? Thanks in advance.
@mariusespejo
@mariusespejo 8 ай бұрын
Hey there, there’s nothing special about using context in storybook. Just as usual you just need to have a provider to your stories, e.g. to provide mock data. Basically just follow typical usage as shown in react docs
@user-zh6hj7ng6s
@user-zh6hj7ng6s 8 ай бұрын
@@mariusespejoReally thanks
@mariusespejo
@mariusespejo 8 ай бұрын
Here’s an example of where you can add decorators wrapping your stories, you can place providers in there storybook.js.org/docs/writing-stories/decorators#story-decorators
@user-zh6hj7ng6s
@user-zh6hj7ng6s 8 ай бұрын
@@mariusespejoThank you very much.
@david_kent7302
@david_kent7302 Жыл бұрын
Great video! Curious to know your theme you're using.
@elkhial
@elkhial 2 ай бұрын
Adding this to the config object in main.ts makes the UI read the comments on PAGE REFRESH without having to restart the sevre. typescript: { reactDocgen: 'react-docgen', },
@paieu
@paieu 8 ай бұрын
I learnt something today:: anyway thanks hehe
@mariusespejo
@mariusespejo 8 ай бұрын
😄
@IneyeGabriel
@IneyeGabriel Жыл бұрын
Do you have a discord I can follow? Your teaching is clear. The video quality is superb, and the sound is great.
@mariusespejo
@mariusespejo Жыл бұрын
Thank you! I don’t at this time but will think about it
@rufok5336
@rufok5336 Жыл бұрын
Can you make another video for storybook? This was really useful thank you so much!!
@mariusespejo
@mariusespejo Жыл бұрын
I can think about it! Was there something specific that you thought was missing in the video?
@rufok5336
@rufok5336 Жыл бұрын
@@mariusespejo I received an internship offer for a really nice company which they asked me to look at Storybook and this video was amazing from someone who never coded in my life hahaha Probably I would like to know more how it is used in a professional environment with examples etc
@mariusespejo
@mariusespejo Жыл бұрын
Ah I see, to a degree the fundamentals are all here. It honestly is mostly about isolated development, documentation, and testing. I do have a video on storybook interaction testing. You also can find a bunch of public company storybooks you can use to see how others are using it. Most people would use it to build design systems, component libraries, etc. Will think about other video topics for this space. Anyways good luck on your internship!
@jacqueskorb879
@jacqueskorb879 6 ай бұрын
Hi. Thank you. How do I change my existing stories seeing that ComponentStory, ComponentMeta does not exist anymore in the latest version of Storybook? Any ideas? Tx in advance.
@mariusespejo
@mariusespejo 6 ай бұрын
In newer versions of storybook if you use their upgrade command it typically will auto migrate some changes for you.
@skoizumi291101
@skoizumi291101 8 ай бұрын
Thanks for the great video. I have one question. What we be the development workflow once you are done the development? Copy and paste? Or is there any easier and better way to bring this to my application?
@mariusespejo
@mariusespejo 8 ай бұрын
Sorry not sure I understand your question. Creating stories itself is one of the development workflows. Build components and use them as usual.
@dawid_dahl
@dawid_dahl Жыл бұрын
Thank you! 🙏🏻
@victorolimpio91
@victorolimpio91 Жыл бұрын
Great video! you hard define variant props as 'green' on the Light component why the stories args was able to change the circle's color?
@mariusespejo
@mariusespejo Жыл бұрын
That’s kind of the point of args, you can set an initial prop but the controls allows you dynamically update. The core idea is it’s like documentation that isn’t static, you can play around with it
@artem_zakharchuk
@artem_zakharchuk 8 ай бұрын
It is very explicit, thank you! I have signed up) I use stories only to develop small Components, right? And for the App, I should use a simple Component with props (like Light.ts in your video)? I know that it is quite a stupid question, but still)
@mariusespejo
@mariusespejo 8 ай бұрын
There is no restriction on how “small” but the point is that you start with small and those components you should be able to compose into larger components which those could have stories as well
@sergeyfilippov2522
@sergeyfilippov2522 Жыл бұрын
thx, diamond lesson )
@tzuilee588
@tzuilee588 Жыл бұрын
Yo, nice content man!
@mariusespejo
@mariusespejo Жыл бұрын
Thanks!
@user-fh2po8id9e
@user-fh2po8id9e 9 ай бұрын
how can i add boostrap to storybook, i try to run it but my styles are not showing
@mariusespejo
@mariusespejo 9 ай бұрын
Need to import the css in the preview.js storybook.js.org/recipes/bootstrap
@vidyasagarkushwaha8080
@vidyasagarkushwaha8080 4 ай бұрын
Please make view with redux and router setup
@poojaagarwal2041
@poojaagarwal2041 Жыл бұрын
hey am create boilerplate react with antd 5, styled-component, typescript, storybook 7 but I am confused to how can i add antd 5 css customisation file in storybook preview.js file
@poojaagarwal2041
@poojaagarwal2041 Жыл бұрын
import React from "react"; import { StoryObj, Meta } from "@storybook/react"; import Button from "./Button"; export default { title: "Components/Button", component: Button, } as Meta; // type individual stories type Story = StoryObj; export const Base: Story = { args: {}, }; export const Another: Story = { args: { label = "Button", }, render: (args) => , }; i am create same as your tutorial but strill getting error 'Button' refers to a value, but is being used as a type here. Did you mean 'typeof Button'?
@danielguldbergaaes6432
@danielguldbergaaes6432 Жыл бұрын
Thanks for another great video! Can I ask which browser you are using, it looks really nice!
@mariusespejo
@mariusespejo Жыл бұрын
The Ark browser! Check it out it’s pretty cool
@danielguldbergaaes6432
@danielguldbergaaes6432 Жыл бұрын
@@mariusespejo Thanks! It seems like I'm not cool enough to get access to it yet though ;)
@mariusespejo
@mariusespejo Жыл бұрын
I was on the waitlist for maybe a week or two, it shouldn’t take long!
@danielguldbergaaes6432
@danielguldbergaaes6432 Жыл бұрын
@@mariusespejo Got it today :D what did you do to get that topbar isntead of the sidebar? if you don't mind me asking.
@mariusespejo
@mariusespejo Жыл бұрын
I think it automatically does that for localhost but for any other site you can click on the little info icon next to the url and set it to developer mode. It’s on a per site basis unfortunately
@TheSodaMaster87
@TheSodaMaster87 Жыл бұрын
IDK whats going on, I follow every one of these tutorials step by step exactly and it always ends up breaking or crashing in someway. I get this error : Can't resolve "./Light" not sure why this is doing this...
@mariusespejo
@mariusespejo Жыл бұрын
Are you sure you’re importing with the right path?
@TheSodaMaster87
@TheSodaMaster87 Жыл бұрын
@@mariusespejo Just figured it out, I just had to restart StoryBook. For some reason, it was giving me errors over an old component I had already deleted..but it didnt register until restarting StoryBook. Thanks man
@user-rm1dj7sk4c
@user-rm1dj7sk4c Жыл бұрын
👍
@nguyenkhoi3775
@nguyenkhoi3775 Жыл бұрын
Do you know the way to publish this package on npm
@mariusespejo
@mariusespejo Жыл бұрын
You can use tools like rollup to bundle your code, the rest of how to publish I suggest reading npm docs
@sauravbhagat4737
@sauravbhagat4737 Жыл бұрын
How to build this project for deploying this to npm?
@mariusespejo
@mariusespejo Жыл бұрын
You need a tool designed for doing those kinds of builds, take a look at tsdx as an example or you can use rollup if you want to configure it yourself
@sauravbhagat4737
@sauravbhagat4737 Жыл бұрын
@@mariusespejo I think tsdx is too outdated now. Have you used it recently?
@mariusespejo
@mariusespejo Жыл бұрын
i don’t know that i would call it outdated, it still solves the same problem although perhaps just not being actively maintained. There is a fork of it called dts-cli that you can perhaps consider. Again also if you’re concerned then you can configure tools like rollup yourself, tsdx is just the zero config get started quickly path to that
@sauravbhagat4737
@sauravbhagat4737 Жыл бұрын
@@mariusespejo just FYR Tried tsdx, lot of errors due to internal roll-up version conflicts. As you've suggested, using vite + roll-up config. It's working fine now. Thanks
@user-db7fu5yo6i
@user-db7fu5yo6i Жыл бұрын
Could you share link for github repo please?
@mariusespejo
@mariusespejo Жыл бұрын
It’s not in a repo at the moment, I recommend just coding along with the video, there’s not much code written
@jkmoijul8559
@jkmoijul8559 Жыл бұрын
can you share link to the source code?
@mariusespejo
@mariusespejo Жыл бұрын
It’s not on a repo. Honestly if you watch the video it’s literally just running two commands (vite & storybook) and writing the two files… it would take you 5min to write
@kacperkepinski4990
@kacperkepinski4990 5 ай бұрын
you missed steps
@mariusespejo
@mariusespejo 5 ай бұрын
What do you mean?
@henriquekramer_
@henriquekramer_ 7 ай бұрын
thanks
@SkippyMcfee
@SkippyMcfee Жыл бұрын
Thank you!!!
Every React Concept Explained in 12 Minutes
11:53
Code Bootcamp
Рет қаралды 610 М.
Начало работы со StoryBook
23:42
Михаил Непомнящий
Рет қаралды 49 М.
Now it’s my turn ! 😂🥹 @danilisboom  #tiktok #elsarca
00:20
Elsa Arca
Рет қаралды 12 МЛН
هذه الحلوى قد تقتلني 😱🍬
00:22
Cool Tool SHORTS Arabic
Рет қаралды 93 МЛН
Throwing Swords From My Blue Cybertruck
00:32
Mini Katana
Рет қаралды 11 МЛН
1ОШБ Да Вінчі навчання
00:14
AIRSOFT BALAN
Рет қаралды 5 МЛН
Storybook - Быстрый курс по работе и тестированию с React
37:39
React JS Component Testing with Storybook 7 Typescript
21:49
Marius Espejo
Рет қаралды 8 М.
TypeScript in React - COMPLETE Tutorial (Crash Course)
53:21
ByteGrad
Рет қаралды 243 М.
React vs Angular in 2024
9:00
Kodaps Academy
Рет қаралды 49 М.
Я 💛 Фронтенд. Я ❤ Storybook - Семён Левенсон
44:40
Decouple your NestJS code with this technique!
11:37
Marius Espejo
Рет қаралды 37 М.
Why Storybook React Makes Building UI Components Easy
6:19
CBT Nuggets
Рет қаралды 4,4 М.
Storybook in 100 Seconds
2:19
Fireship
Рет қаралды 469 М.
Now it’s my turn ! 😂🥹 @danilisboom  #tiktok #elsarca
00:20
Elsa Arca
Рет қаралды 12 МЛН