flow-js2-mode icon indicating copy to clipboard operation
flow-js2-mode copied to clipboard

Add HACKING info

Open charlag opened this issue 5 years ago • 4 comments

Hey! I'm relatively new to Emacs and to Elisp in particular but I really want to see flow mode working on Emacs.

I had to do some research before figuring out how to run tests. I think they fail but I'm not sure how to debug them, it worked once but not anymore. If you have an advice I would add this do this document gladly.

If I can figure it out well enough, I can try to make a tutorial because I almost don't see any info on creating Emacs packages.

charlag avatar Mar 23 '19 15:03 charlag

Maybe it would make more sense to include this in the readme file directly. We can split it out later, but currently there's not a lot of information.

We've moved from flow to typescript so I'm not really updating this very much. For what I wanted it worked fine. More complicated things I unfortunately have no capacity to fix.

Fuco1 avatar Mar 23 '19 16:03 Fuco1

I will change PR to include it into README. I understand that you're not working on this anymore but I would like to try and pick up what's possible. I'm grateful for what you did. Do you have any hint about debugging this code? Did you use edebug or something similar?

charlag avatar Mar 23 '19 16:03 charlag

Yes, edebug is very helpful.

This package works by adding features to js2-mode so you need to really understand that one first... and it's a really odd package. If you have some specific questions I will try to point you in a right direction, but even for me it was mostly trial and error.

Fuco1 avatar Mar 23 '19 20:03 Fuco1

I changed it to add it to README. Yeah, I figured that it pulls some of the js2-mode strings. Very helpful would be to know your workflow. Like, we have a file with test (current tests fail I think). I can either run it from shell (like I pointed in the example), or I could try to do this interactively. I can tell edebug to break at the function or at the line but I don't know how to run tests in a way that edebug would work.

charlag avatar Mar 25 '19 19:03 charlag