riot-router icon indicating copy to clipboard operation
riot-router copied to clipboard

breaks on riot 3

Open mikey0000 opened this issue 8 years ago • 5 comments

riot-route is now a seperate module.

mikey0000 avatar Dec 01 '16 07:12 mikey0000

I forked and updated the router to work with riot 3. It's a breaking change tho. Check out https://github.com/blub0hr/riot-router

I am up to create a pull request but not sure about the breaking changes yet.

blub0hr avatar Jan 12 '17 15:01 blub0hr

Hi @blub0hr ! Thank you for your work.

I'm also trying to make compatible. I'm having some difficulties with the tests, but I believe this change will allow you to use the riot-router with riot 2 and riot 3. I need to test it better to be sure. If it does not work, I'll only be compatible with riot-3.

If you want to take a look, see also in this branch: https://github.com/gabrielmoreira/riot-router/tree/riot3

gabrielmoreira avatar Jan 14 '17 16:01 gabrielmoreira

how is this coming along? I'm currently refactoring for a Riot2 -> Riot3 upgrade and have had to write my own router. Getting some issues, so it'd be great if I could use your new one in our project ... how ready is it?

stukennedy avatar Jan 16 '17 13:01 stukennedy

@continuata @blub0hr

I've released version 0.9.x with support for Riot 3. I'm using this version in a project that will be put into production, and for now I had no problems.

I had to adjust some things. The router is now accessible in the window.router variable, and has a direct dependency on the riot-route. https://unpkg.com/[email protected]/dist/router.min.js

If you prefer, you can use the router.core, which has no dependency on riot-route. https://unpkg.com/[email protected]/dist/router.core.min.js

var router = window.router = Router.create({ route: require ('riot-route') });

Unfortunately I did not have time to do good documentation, and update the page.

gabrielmoreira avatar Jan 20 '17 13:01 gabrielmoreira

Thanks a lot. I'll be using it in production as well soonish.

blub0hr avatar Jan 23 '17 11:01 blub0hr