Add meta.origin to our saveAction if NODE_ENV != production #102
No reviewers
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
MichaelContento/redux-storage!102
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "saveAction-meta-origin"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes #100
@mathieudutour Do you have a opinion about this? You're quite active on this project and I'd love to hear your feedback 😄
Yeah it might be useful. This is a breaking change though. And you need to add
to the package.json
@mathieudutour I've added envify (the faster variant named loose-envify - the same as redux is using).
But why should this be a breaking change? It does not manipulate the actual payload of the save action. I though of this as a minor release
Because of someone is already using the origin meta, it breaks.
For it to be non-breaking, it needs to be opt-in
On 29 Feb 2016, at 08:51, Michael Contento notifications@github.com wrote:
@mathieudutour https://github.com/mathieudutour I've added envify (the
faster variant named loose-envify https://github.com/zertosh/loose-envify
https://github.com/reactjs/redux/blob/master/package.json#L116-L120 is
using).
But why should this be a breaking change? It does not manipulate the actual
payload of the save action. I though of this as a minor release
—
Reply to this email directly or view it on GitHub
https://github.com/michaelcontento/redux-storage/pull/102#issuecomment-190107501
.
Oh! You mean if someone hijacks and mutates the saveAction while it is been processed? Good point! Although this sounds more like a redux anti-pattern to me 😄
But as this is a good point, it will be part of the upcoming 4.0.0 together with the
fromJSchanges 👍NOTE: Branch rebased as
browserify-envifyis already required in the current masterNo not necessary. I have some middlewares checking for the existence of a
meta key to trigger a side effect. Someone could have one of those
listening to the origin meta key
On 29 Feb 2016, at 09:16, Michael Contento notifications@github.com wrote:
Oh! You mean if someone hijacks and mutates the saveAction while it is been
processed? Good point! Although this sounds more like a redux anti-pattern
to me [image: 😄]
But as this is a good point, it will be part of the upcoming 4.0.0 together
with the fromJS changes [image: 👍]
—
Reply to this email directly or view it on GitHub
https://github.com/michaelcontento/redux-storage/pull/102#issuecomment-190115959
.