I'm not sure what is the state of this plugin concerning RSC but I encountered a possible bug while trying to integrate vite-plugin-stylex with vinxi react RSC.
It works fine for spa and ssr (haven't tried in prod yet) but for some reason when I include vite-plugin-stylex in my rsc router import.meta is undefined and breaks the application.
Doesn't matter if it's stylex or react-strcit-dom I always get Cannot read properties of undefined (reading 'ROUTER_NAME') when import.meta.env.ROUTER_NAME is being accessed.
I'm not sure what is the state of this plugin concerning RSC but I encountered a possible bug while trying to integrate vite-plugin-stylex with vinxi react RSC.
It works fine for spa and ssr (haven't tried in prod yet) but for some reason when I include vite-plugin-stylex in my rsc router
import.meta
is undefined and breaks the application.Doesn't matter if it's stylex or react-strcit-dom I always get
Cannot read properties of undefined (reading 'ROUTER_NAME')
whenimport.meta.env.ROUTER_NAME
is being accessed.This is the example I'm using.