I'm using the Apartment gem to build a multi-tenant app (each tenant lives in a different Postgres schema).
What's the best way in Rails to define custom CSS overrides for each tenant?
I'm using the Apartment gem to build a multi-tenant app (each tenant lives in a different Postgres schema).
What's the best way in Rails to define custom CSS overrides for each tenant?
Given that multi-tenancy is itself a deviation from the rails way of doing things, I am not sure there a definitive answer to be provided here.
I recommend the following approach, which I think fits well with your use case:
In your layout:
In your scss files:
For each tenant (say t1) you can have:
tenant_t1.css.scss