-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Import-Export States to your DevTools #118
Conversation
Only that we're splitting |
Haha, I love how you define this as a long wait, when it's been a week. I was just wondering if it had fallen through the cracks 😄 No problem there though, apparently. Keep up the great work! Btw (and sorta related), is there any possibility of getting a sync between browsers/sessions? So you can have different browsers up at the same time all getting the same data automatically. I sorta have it now using browsersync, but that syncs clicks and inputs, and not actual state, which would be nicer, IMO. If it's available, or discussed in another issue, apologies. |
You can implement this as a store enhancer for regular Redux—it will work with Redux DevTools just fine. You can use |
Can I ask you to tweak this to:
? |
break; | ||
case ActionTypes.IMPORT: | ||
( | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove extra indentation and line break here.
This is fine:
({
stagedActions,
...
} = liftedAction.newState);
Let's also rename newState
to nextLiftedState
.
sounds good! I'll try to make the changes today 👍 |
There you go. Let me know if all is good and I can squash those commits into one. There are a couple of "issues" (not really issues but worth bringing up) I ran into:
Thanks guys! |
@@ -3,6 +3,7 @@ const ActionTypes = { | |||
RESET: 'RESET', | |||
ROLLBACK: 'ROLLBACK', | |||
COMMIT: 'COMMIT', | |||
IMPORT: 'IMPORT', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's call it IMPORT_STATE
yup
44eeed7
to
939eb78
Compare
Updated 👍 |
One more thing: can you please add some tests? |
Busy couple of days at work. I'll try and add the tests before the end of the week! |
Sure, thanks! Sorry I'm a bit stuck here too—on a vacation. |
939eb78
to
730d54e
Compare
Tests added! Let me know if anything is missing |
730d54e
to
b17edef
Compare
b17edef
to
4e3b362
Compare
I'm bringing this in via b4da7aa in vNext branch. |
I've put together a small addition to the code that would allow us to import and export action logs.
Export
button added to top bar.textarea
and paste it on another session running the app.This feature (or something similar) would be awesome to use for QA purposes among other things.