LunatiqueCoder / luna

Luna - a React Native + Next.js template. Built with TypeScript :heart:
https://luna-gamma.vercel.app/
MIT License
264 stars 17 forks source link

Next js server do Fast Refresh with full reload #92

Closed Oleksiiithouse closed 9 months ago

Oleksiiithouse commented 9 months ago

Describe the bug I guess that Fast Refresh do not work well because of react-native-web should recompile react-native syntax to html etc. But I don't understand why in between saving changes in project and reloading I can notice that my changes was recompiled and loaded by browser, but Fast Refresh anyways reloading page. Could you recommend how to fix because I believe that ~70% Fast Refreshes could perform w/o reloadings? Or please explain why it is not possible or enough complicated to do.

To Reproduce The behavior appears in original empty project.

Expected behavior Less amount of reloadings.

LunatiqueCoder commented 9 months ago

Hey @Oleksiiithouse

Really happy that you tried luna! Unfortunately, I'm not actively using this setup anymore, so I cannot help much on this matter 🥲

Oleksiiithouse commented 9 months ago

I found a solution! Problem was related to a bug in next.js sources in version 13.2. that was as default in this boilerplate package.json. Bug was fixed by next.js devs, so solution for me was to install version 13.5.6 (with the newest v14. do not work). bug issue

LunatiqueCoder commented 8 months ago

So happy that you could find the issue :) Even happier if this template helped you.