Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DO NOT MERGE - EXAMPLE Thunk actions#9 #211

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

hardchor
Copy link
Owner

No description provided.

@hardchor hardchor added review and removed review labels Oct 31, 2016

export const INCREMENT_COUNTER = 'INCREMENT_COUNTER';

export function increment() {
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A standard FSA-complaint action

};
}

export function incrementBy(step) {
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FSA with a payload

};
}

export function incrementAsync() {
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

redux-thunk action that triggers FSA renderer-side

};
}

export function incrementByAsync(step) {
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

redux-thunk action that triggers FSA with payload

};
}

export const incrementMain = createAliasedAction(
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

aliased action that triggers FSA main-side

increment
);

export const incrementAsyncMain = createAliasedAction(
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

aliased action that triggers thunk action (which produces FSA) main-side (recommended)

incrementAsync
);

export const incrementByAsyncMain = createAliasedAction(
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same as above, with payload (recommended)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant