skip to Main Content

I’ve already developed and deployed ReactJS app with separated front and backend (Laravel).

I’m facing issue with sharing pages with dynamic data due to the disability of react to dynamically generating meta tags, No dynamic preview , no dynamic title .

After searching the web for days the only stable solution found is migrating to NextJs.

my question is can i migrate ( partially ) to Nextjs ?

using Nextjs router for only the sharable pages and preserve the react router for the rest pages?
or any other solution other than nextjs for that issue ?

2

Answers


  1. nextjs offer ssr and csr same time.
    my suggestion is that you create a nextjs project and create all your routing as folder in page file. and copy your routed component in these folderand create a folder named "components" and copy your child component inside them.
    some difficulty may occur for localstorage or parameters etc …
    after that you run your app without error you can see all your pages as csr rendering.
    so for seo sake!! you need to go to those page that need to be seo freindly and change them to ssr.

    Login or Signup to reply.
  2. I’m not sure why you want to migrate partially because I think NextJS offers exactly what you want.

    1. It can generate meta tags dynamically (see next/head)
    2. Using Vercel OG, you can even have dynamic OG images (dynamic preview)

    But to answer your question, no you cannot partially migrate to NextJS because it’s not just a library. it’s a framework.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search