Description
Maybe I'm missing something, but shouldn't it be possible to have multiple separate importmaps? :)
My app has three distinct parts/namespaces ("web" for the public marketing page, "admin" for the admin area, and "clients" for the login area for clients) and for each I'd like to have different pinned (and preloaded) modules.
Right now I'm solving it by keeping three different Importmap::Map
s around and delegating Rails.application.importmap
to Current.importmap
, which loads the correct importmap for the current namespace, but that seems to be much more complicated than it should be.
I'm sure I'm not the only one that has multiple distinct namespaces in their app? :)
Is there another way to solve this?
Happy to have a stab at implementing this if it's a welcomed feature.