Next.js Discord

Discord Forum

Multi-tenant css with pages router

Unanswered
Elm sawfly posted this in #help-forum
Open in Discord
Avatar
Elm sawflyOP
We need to be able to load a different CSS file depending on what tenant is loading. But next.js only allows one CSS file import - in the app js file before any server data is even loaded. How can I load a different CSS file depending on what tenant it is for?

We have to use the pages router (we tried app router, and it had too many design flaws for us)

4 Replies

Avatar
Transvaal lion
@Elm sawfly It seems like we're doing similar things... I'm also working on a multi-tenant application, and also spun my wheels with app router (now trying pages router). Would you mind if I DM you so we can share notes?
Avatar
Elm sawflyOP
sure thing!
Avatar
Jagdterrier
Hi, please could you explain how did you or what tools did you use to implement multi-tenant with pages router? Ive been googling for hours, but all results are based on app router..
Avatar
Jagdterrier
@Transvaal lion