Skip to content
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

Prepare for React Router 7 #67

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open

Prepare for React Router 7 #67

wants to merge 8 commits into from

Conversation

jarle
Copy link
Owner

@jarle jarle commented Sep 21, 2024

No description provided.

@HananoshikaYomaru
Copy link

HananoshikaYomaru commented Oct 16, 2024

Hi, I just want to say a thanks to you for making this. I have been looking for remix and adonis integration and you make it very easy to use. I am very happy to see the plan to integrate react router 7 because that makes me believe that this project has received support for the future.

@jarle
Copy link
Owner Author

jarle commented Oct 18, 2024

Thank you! I use the library for my own projects, and luckily there isn't much maintenance needed to keep it up to date 🙌

@HananoshikaYomaru
Copy link

I have a very huge remix project and planning to migrate to adonis. I am trying to be cautious. Is there any caveats or limitation when using remix with adonis, especially the v3 flags (single-fetch) or server context and middleware in the future?

These features are still under development but I want to know how you think about those features since middleware and server context might have overlapping with the current remix adonis setup. Do you think they will be in-compatible with each other or they will work together just fine?

@jarle
Copy link
Owner Author

jarle commented Oct 21, 2024

I'm very positive about the upcoming changes to middleware and server context - both make it easier to integrate the adapter with Remix.

If I understand the server context correctly, it could be a drop-in replacement of how we do service providers: https://matstack.dev/remix-adonisjs/technical-details/accessing-services#setting-up-helper-functions-for-service-providers

I also believe Remix middleware will improve how we do auth middleware with AdonisJS. The current auth middleware suggestion in the docs is not pretty, so it will be improved significantly if we can declare middleware from the remix app routes.

@Bricklou
Copy link

Bricklou commented Dec 14, 2024

Vite 6 support in Adonis just dropped, and React Router 7 released 3 weeks ago.
Everything is finally ready, so the upgrade can begin! 😄

Edit: after some investigation, RR7 still has some issues with Vite 6 (remix-run/react-router#12469, remix-run/remix/pull/10254, remix-run/remix/pull/10255)

@jarle
Copy link
Owner Author

jarle commented Dec 15, 2024

Vite 6 support in Adonis just dropped, and React Router 7 released 3 weeks ago. Everything is finally ready, so the upgrade can begin! 😄

Edit: after some investigation, RR7 still has some issues with Vite 6 (remix-run/react-router#12469, remix-run/remix/pull/10254, remix-run/remix/pull/10255)

Nice, thanks for the contribution! I have made some changes so it should be possible to use with react-router now. The starter kit is available on react-router now by running

npm init adonisjs@latest -- -K="github:jarle/remix-starter-kit#support-rr7"

and the typical changes needed for the migration can be seen in this PR: jarle/remix-starter-kit#47

There is still a little work needed to make react-router the default, but it should be possible to use today with the correct setup.

@Bricklou
Copy link

Hey ! Small update: React Router now support Vite 6 ! (remix-run/react-router#12469)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants