-
Notifications
You must be signed in to change notification settings - Fork 86
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
Add time-traveling debugger #18
Comments
I think @mastoj is already working on something similar for fable-arch. |
Cool maybe should join forces. @mastoj Where can I find the current state of the art? |
Check the plugin sample of fable-arch.
|
do you hava a link? |
http://fable.io/fable-arch/samples/plugin/index.html On Fri, 18 Nov 2016 at 14:36, Steffen Forkmann notifications@github.com
|
I was thinking to check Redux tools/debugger needs and see if there could be a layer implemented in |
cool. so where can I read about this thingy? I don't really understand how to use it. Also are you planning to do export/import? |
@et AFAIK debugger is in 0.18 |
@forki , I've been thinking about export import, but haven't got the time to do it. Also, I haven't done much with documentation. Basically it's just another app that is running side by side with the applications that listens for all events. I've opened up my abstractions to replay events so the devtools can feed events back to the applications that is being monitored. |
Found the Elm debugger here: https://github.com/elm-lang/virtual-dom/blob/master/src/VirtualDom/Debug.elm Conceptually, the Elm debugger is a It's not much use for elmish as it is however: Since it has visual elements, it has to be split into |
There's an integration with Redux DevTools Extension: https://twitter.com/FableCompiler/status/772745186287947776 Redux DevTools Extension can be integrated easily with any architecture, if you need more details on this, let me know. |
Fantastic! I love Redux DevTools Extension and actually it's already possible to use it with Fable but being able to use it natively with fable-elmish and fable-arch would be just so awesome. Thanks a lot for your help, @zalmoxisus! |
@alfonsogarciacaro, you can send messages to it from anywhere via sockets, like |
Looks promising, thanks Mihail! |
@forki Seems the sockets client would be the way to go for hooking up Native debugging. It could go into |
Yeah currently I took up another challenge. So I guess this is out of scope Am 22.11.2016 15:50 schrieb "Eugene Tolmachev" notifications@github.com: @forki https://github.com/forki Seems the sockets client would be the way — |
@zalmoxisus I wonder if I could ask your help investigating the weird behavior I'm seeing. I'm suspecting that either my code or fable is doing something wrong, but I can't tell what. Symptoms, using the Chrome extension:
using the local server and a stand-alone monitor:
The counter sample has the transpiled F# checked in (in Thanks in advance! |
Hey @et1975, At first, when trying to open the example, for some reason, I get
I guess you're getting I fixed it in zalmoxisus/remotedev@7650a40. Updating to var sub = function sub(dispatch) {
connection.subscribe(function (msg) {
var state = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_5_remotedev__["extractState"])()(msg);
program.setState(state)(dispatch);
});
}; BTW, few days ago, I wrote a draft of the API, where you can find more details of the types beside
You're sending
I don't seem to reproduce that. Just added the
Could you please check if in this case the extension's script was loaded after you try to call it (check if
That's a sign that you're subscribing to the channel twice. Maybe that API draft could help. |
Yes, it's only in remotedev, not in the extension. Probably it's worth having a default
I was wrong here, it's about emitting not subscribing. Hard to say what could be the reason without a repro.
Could you please provide some steps to reproduce? I tried to reload several time the app window and the extension window and still not getting that issue. You can press |
that would be pretty sweet, although if I may offer a "functional" twist, define it something like:
Something like:
At this point it's messed up and won't work until I reopen the SPA tab. |
Related to elmish/elmish#18 (comment) 1423290
Could you please try to update the extension? I just published Also I had to change in var subscribe = function subscribe(model) {
var sub = function sub(dispatch) {
connection.subscribe(function (msg) {
- var state = extractState()(msg);
+ var state = extractState(msg);
- program.setState(state)(dispatch);
+ if (typeof state !== 'undefined') program.setState(state)(dispatch);
});
};
return CmdModule.batch(ofArray([ofArray([sub]), program.subscribe(model)]));
}; |
@zalmoxisus Thank you, works flawlessly via the extension! I'll try RN stuff in a bit... |
@et1975, glad to know. I've just added that function also in |
@zalmoxisus works with Native and local server too! Thanks, Misha! |
There's a known issue, specifically about the counter samples - it uses a simple |
Related to elmish/elmish#18 (comment) 1423290
http://elm-lang.org/blog/the-perfect-bug-report
I think I want to give it a shot.
/cc @et1975 @alfonsogarciacaro
The text was updated successfully, but these errors were encountered: