Different documentations and guides make alt hard to pick up
Nimelrian opened this issue · 1 comments
Nimelrian commented
So, we just started using alt instead of Redux for a new project.
Up till now we followed the Getting Started guide on the homepage, so we have for example
handleAddMachine(machine) {
this.machines.push(machine);
}
Today I looked something up on the Github Repository and found that following the examples in the README.md I'd use this:
handleAddMachine(machine) {
this.setState({
machines: this.state.machines.concat(machine)
});
}
I recognized the 2nd pattern from Redux, promoting immutability and using non-mutating operations.
Which one is the officially recommended one?
Having different documentations and approaches is horrible for the user. Especially if (what I think it is) the recommended way using setState is hidden here in the repository and not on the homepage of the library.
diessica commented
I'd be happy to work on this.