E545 fix: nativewind theme functions on web by sjwall · Pull Request #1346 · nativewind/nativewind · GitHub
[go: up one dir, main page]

Skip to content

Conversation

sjwall
Copy link
Contributor
@sjwall sjwall commented Nov 25, 2024

Fixes #1160 and #1179

The platformSelect function when running on web is using the native version when NATIVEWIND_OS is set to web.

Using the #1160 example repo

Putting a console.log(process.env.NATIVEWIND_OS) in tailwind config is always printing undefined when building for web.
But logging to a file instead results in web being printed:

if (process.env.NATIVEWIND_OS !== undefined) {
  writeFileSync(file, process.env.NATIVEWIND_OS);
}

I tried adding test cases but couldn't get the NATIVEWIND_OS environment variable to be set to undefined in the test case.

Copy link
vercel bot commented Nov 25, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
nativewind ✅ Ready (Inspect) Visit Preview Nov 25, 2024 11:48am

@sjwall
Copy link
Contributor Author
sjwall commented Dec 5, 2024

Hey @marklawlor are you able to look at reviewing this please?

@danstepanov
Copy link
Member

I'll play around with this over the weekend and follow up

@danstepanov danstepanov self-assigned this Mar 1, 2025
@sjwall
Copy link
Contributor Author
sjwall commented Mar 10, 2025

How did you get on with the change?

@danstepanov
Copy link
Member

I'll take a look at this PR tomorrow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

platformSelect not working in v4
2 participants
0