We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
NATIVEWIND_OS
1 parent 2590cd8 commit 175a60aCopy full SHA for 175a60a
2 files changed
.changeset/plugin-nativewind.md
@@ -0,0 +1,6 @@
1
+---
2
+'@callstack/repack': patch
3
+'@callstack/repack-plugin-nativewind': patch
4
5
+
6
+Fix platform detection for NativeWind via `NATIVEWIND_OS` env var
packages/plugin-nativewind/src/plugin.ts
@@ -106,6 +106,11 @@ export class NativeWindPlugin implements RspackPluginInstance {
106
if (this.options.checkDependencies) {
107
this.ensureNativewindDependenciesInstalled(compiler.context);
108
}
109
+ /** Set the platform if not present*/
110
+ const platformName = compiler.options.name;
111
+ if (process.env.NATIVEWIND_OS === undefined) {
112
+ process.env.NATIVEWIND_OS = platformName;
113
+ }
114
115
/**
116
* First, we need to process the CSS files using PostCSS.
0 commit comments