𝐁𝐏
https://share.effector.dev/JGckj07d
Size: a a a
𝐁𝐏
DS
следствие
достижения модели или части модели определенного состояния.первичной загрузке.
URL => point of app state
(model)
`````````````````````````````browser history navigation => point of app state (model)
``````````````````````````````````````````````````point of app state
(model) => URL
`````````````````````````````points navigation => browser history
stack
yv
𝐁𝐏
𝐁𝐏
yv
yv
𝐁𝐏
VI
𝐁𝐏
forward
и .?
Когда используем effect, то для изменения состояния store, нужно его пробрасывать с помощью forward в event?.?
- что б если на данных нельзя применить map, то вывести undefined вместо исключения?yv
forward
и .?
Когда используем effect, то для изменения состояния store, нужно его пробрасывать с помощью forward в event?.?
- что б если на данных нельзя применить map, то вывести undefined вместо исключения?yv
forward
и .?
Когда используем effect, то для изменения состояния store, нужно его пробрасывать с помощью forward в event?.?
- что б если на данных нельзя применить map, то вывести undefined вместо исключения?.?
— это optional chaining и в целом в моём примере не нужен, т.к. в сторе изначально есть пустой массив. если бы стор инициализировался null
, тогда да.𝐁𝐏
l
type Hardware = {
id: number;
title: string;
quantity: number;
price: number;
totalAmount: number;
};
const contentFilled = createEvent<Hardware>();
const $title = hardwareModel.store("");
const $price = hardwareModel.store("");
const $quantity = hardwareModel.store("");
contentFilled({…})
🦜
type Hardware = {
id: number;
title: string;
quantity: number;
price: number;
totalAmount: number;
};
const contentFilled = createEvent<Hardware>();
const $title = hardwareModel.store("");
const $price = hardwareModel.store("");
const $quantity = hardwareModel.store("");
contentFilled({…})
DS
type Hardware = {
id: number;
title: string;
quantity: number;
price: number;
totalAmount: number;
};
const contentFilled = createEvent<Hardware>();
const $title = hardwareModel.store("");
const $price = hardwareModel.store("");
const $quantity = hardwareModel.store("");
contentFilled({…})
l
𝐁𝐏
DS
type Hardware = {
id: number;
title: string;
quantity: number;
price: number;
totalAmount: number;
};
const contentFilled = createEvent<Hardware>();
const $title = hardwareModel.store("");
const $price = hardwareModel.store("");
const $quantity = hardwareModel.store("");
contentFilled({…})
const $title = hardwareModel.store("");
А как это воопще?)l
const $title = hardwareModel.store("");
А как это воопще?)const hardwareModel = createDomain();
const $title = hardwareModel.store(“”);