Тёмный

Write and Test State-Machines with XState and Vitest 

Atila
Подписаться 1,5 тыс.
Просмотров 1,9 тыс.
50% 1

Let's write and test a State Machine with this awesome Developer Experience combo: XState + TypeScript + Vitest 🚀
XState is *the* library for orchestrating complex application states, regardless of framework (it's compatible with all of them, actually). In this video we will have a look on writing our first State Machine with XState, as well as checking a few concepts for State-Machines.
1:05 Setup repository
2:08 State-Machine concepts
6:09 writing some types manually
8:33 Vitest suite setup
12:30 create State-Machine with XState
13:40 XState VSCode Extension
19:49 Stately Inspector (XState VSCode)
26:55 Testing the State-Machine happy path
32:15 Why you should reset your mock counters after each test
35:41 Mock XState context on tests
37:19 Asynchronous test, wait on State transition
39:46 Test error boundaries in your State-Machine
🔗
Matt Pocock's playlist: • React & XState Tutoria...
XState VSCode Extension: marketplace.vi...
Vitest docs: vitest.dev/
XState docs: xstate.js.org/...
XState Viz: stately.ai/viz

Опубликовано:

 

16 окт 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 7   
@valcho
@valcho 2 года назад
We. Need. More. Xstate! Thanks for the informative video
@AtilaDotIO
@AtilaDotIO 2 года назад
Yes. We. Do!!! 😊 I'm very glad you liked it, and thanks a lot for the comment!
@valcho
@valcho 2 года назад
@@AtilaDotIO absolutely! I hope everyone who watches this video shares a comment with their experience with XState and how they've solved testing for their needs.
@SofiaBelchiorinho
@SofiaBelchiorinho 2 года назад
Cool video :) Thanks for this!
@adamtak3128
@adamtak3128 2 года назад
Thanks for the video. I’m wondering, what vscode theme are you using? The colours are really pleasing
@AminRafiq-fw9wn
@AminRafiq-fw9wn Год назад
What is github url of this code ?
@piotrgrobelak9662
@piotrgrobelak9662 Год назад
Good question :) I want to check source of this tests :)
Далее
Это было очень близко...
00:10
Просмотров 2,9 млн
Doing lists right, the Solid way
11:45
Просмотров 1,4 тыс.
XState Docs Speedrun - 2022
1:08:48
Просмотров 26 тыс.
Dump The Keyboard? Draw Your Logic with XState!
28:34
Webinar: State Machines and Actors with XState v5
2:42:17
SolidStart calls for you!
13:56
Просмотров 2,4 тыс.
Webinar: Get started with XState v5
1:13:11
Просмотров 7 тыс.
Solid Nested Reactivity with Stores
7:29
Просмотров 703
This is How I Scrape 99% of Sites
18:27
Просмотров 123 тыс.