react-strict-dom icon indicating copy to clipboard operation
react-strict-dom copied to clipboard

allow passing @stylexjs/babel-plugin aliases through react-strict-dom/babel-preset

Open MoOx opened this issue 8 months ago • 4 comments

Until https://github.com/facebook/stylex/pull/856 is merged and released, this is kind of the only option to be able to write imports like defined in a tsconfig file.

MoOx avatar Apr 12 '25 14:04 MoOx

This just needs to be fixed in stylex

necolas avatar Apr 12 '25 17:04 necolas

Remind me what aliases are needed for? Is it only for resolving the vars files?

necolas avatar Oct 11 '25 00:10 necolas

Basically writing absolute imports like @/components/* for local code, following ts config. Stylex doesn’t yet auto detect paths from tsconfig file so alias is the only way so RSD can resolve paths properly when using this arobase import styles (a common thing this days as it’s in lot of default tsconfig (eg: next default template))

MoOx avatar Oct 11 '25 16:10 MoOx

Yeah but what features require import resolution? Just the ones relying on *.stylex.js files existing?

necolas avatar Oct 11 '25 18:10 necolas