Closed thdk closed 4 years ago
So I've implemented it with my own application here as a kind of 'testing' and unit test also still work.
My plan was not to change behavior, only to add typings for the existing code, however I did made a change small change in code and updated the tests accordingly which you might not want: In case there are no queryparams for a route, then lifecycle methods receive an empty object instead of undefined. That seemed more correct to me and was easier to add generic typings for.
I still plan to make a new repo for mobx-router-example-typescript
, I'll probably start a new repo for this instead of forking the existing mobx-router-example
so both can exist together.
@thdk Thanks for all of your work on mobx-router. I have invited you as a collaborator so feel free to continue the work because I'm not using it anymore
@kitze thanks for the invite, I'll accept it. I understand there are other options to use instead of mobx-router these days (what do you use now? I see you have made react-tiniest-router)
However I still like mobx-router. It might be easier to use for beginners in react and mobx than alternatives (such as hooks?).
It's also small enough for me to understand what it is doing so I think I can manage to maintain mobx-router.
Will you still release the new versions on npm? I could set up ci/cd with google cloud build that will remove the need for manual publishing.
Fixes #89
I still need to test this, but I'm already submitting the PR so you can see already where I want to go with this.
Let me know if you have any doubts on using typescript for mobx-router.