kiliman / remix-flat-routes

Remix package to define routes using the flat-routes convention
MIT License
722 stars 25 forks source link

Migration script does not apply layout routes correctly. #46

Closed nicksrandall closed 1 year ago

nicksrandall commented 1 year ago

I'm trying to migrate my app to remix v2_rotuesConvetion and after running the migrate command, none of my layout routes were properly preserved.

kiliman commented 1 year ago

Yeah, I think v2 works slightly differently than remix-flat-routes, although mine is a superset. So I'll fix the migration tool and it should work for both.

Sorry about that.

jimmed commented 1 year ago

Hey, we're also experiencing this issue -- is there any update on the fix for it? We have a pretty large Remix app and would rather not migrate everything by hand.

Naturally, we're not in any big hurry, as Remix has a very forgiving deprecation strategy.

kiliman commented 1 year ago

It's been a while since I worked on the migration, and I don't have any big v1 projects to test on. Can you send me the file layout? If you don't want to post it publicly, you can email me at kiliman@gmail.com.

Thanks!

nicksrandall commented 1 year ago

In what format would you want this in?

nicksrandall commented 1 year ago

I sent an email with the output from running remix routes in my project.

kiliman commented 1 year ago

Just use the tree command

tree app/routes

You can either paste here or send to kiliman@gmail.com

Thanks!!

kiliman commented 1 year ago

remix routes will work as well. Thanks!

jimmed commented 1 year ago

It's been a while since I worked on the migration, and I don't have any big v1 projects to test on. Can you send me the file layout?

Is this helpful? I've renamed a few of the routes for the sake of obfuscating a private project, but the layout is very much identical to the real project.

Routes as JSX ```jsx ```
kiliman commented 1 year ago

@jimmed Yes, thank you! The more "real-world" examples, the better. @nicksrandall also sent me his, and I've got that one mostly done, so hopefully, yours will cover more edge cases.

nicksrandall commented 1 year ago

Thanks for all the work on this... has there been any progress here?

geemanjs commented 1 year ago

Hey @kiliman,

Going through a similar migration, was wandering if you could post the headway you made and the issues you see with it.

Happy to take it on and finish it off 🙏.

James