Jump to content

Welcome to Xbox-Vibes

Sign In Register
Search In
  • More options...
Find results that contain...
Find results in...

馃嚨馃嚤Biblioteka do zarz膮dzania stanem aplikacji React - Jumper


Grano22
 Share

Recommended Posts

  • xTeam

Zapraszam do zapoznania si臋 z nowym projektem naszego klubu - Cardos Studios

Jest to biblioteka do zarz膮dzania stanem aplikacji w 艣rodowisku React, kt贸ra pozwala na tworzenie logiki akcji odizolowanej od logiki komponentu. 脫w akcje mo偶na wywo艂a膰 w ciale komponentu po zadeklarowaniu w konstruktorze komponentu. Jest to p贸ki co nowatorski projekt, kt贸ry b臋dzie stopniowo rozwijany.

https://xbox-vibes.com/index.php?/clubs/page/6-bliblioteka-to-zarz膮dzania-stanem-aplikacji-w-react-jumper/

Przyk艂ad u偶ycia:

Dekorator akcji:

classExampleActionextendsActionOperation聽{
聽聽聽聽name聽=聽"Example聽action聽name";
聽聽聽聽description聽=聽"Example聽action聽description";
聽聽聽聽//Zdarzenia聽akcji
聽聽聽聽onStore(component,聽inputData)聽{
聽聽聽聽聽聽聽聽component.currDocument.removeSlide(inputData.slideID聽-聽1);
聽聽聽聽聽聽聽聽if(component.state.currSlide>inputData.slideID)聽return聽{currSlide:component.state.currSlide-1};
聽聽聽聽}
聽聽聽聽onRestore(component,聽inputData)聽{
聽聽聽聽聽聽聽聽/*聽Logika聽zdarzenia聽*/
聽聽聽聽}
聽聽聽聽onFlush(component,聽inputData)聽{
聽聽聽聽聽聽聽聽/*聽Logika聽zdarzenia聽*/
聽聽聽聽}
}

Przyk艂ad dodania akcji:

component.actions.addOperation(newExampleAction(),聽{
聽聽聽聽聽聽聽聽聽聽聽聽presentationElement:elem[i]聽聽/*聽Input聽Data聽*/
聽});

____________________________________________________________________________________________________________________________________________________________________________

jumper.react.png

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy