Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question] How to configure nativewind in @nrwl/expo app? #376

Closed
SurjitSahoo opened this issue Dec 30, 2022 · 2 comments
Closed

[Question] How to configure nativewind in @nrwl/expo app? #376

SurjitSahoo opened this issue Dec 30, 2022 · 2 comments

Comments

@SurjitSahoo
Copy link

I'm trying to configure nativewind in my nx app generated with @nrwl/expo. I followed official doc at https://www.nativewind.dev/quick-starts/expo

yarn add nativewind
yarn add --dev tailwindcss
// tailwind.config.js

module.exports = {
  content: ['./src/app/**/*.{js,jsx,ts,tsx}'],
  theme: {
    extend: {},
  },
  plugins: [],
}
// babel.config.js
module.exports = function (api) {
  api.cache(true);
  return {
    presets: ['babel-preset-expo'],
    plugins: ['nativewind/babel'],
  };
};

I get the following error

iOS Bundling failed 95ms
error: src/app/App.tsx: /Volumes/Storage/work/nx-app/apps/my-app/src/app/App.tsx: Failed to parse declaration "boxShadow: 0 1px 2px 0 rgb(0 0 0 / 0.05)"

What am I missing?

@algoflows
Copy link

I am running into issues as well!

@caroguerrerosilvera
Copy link

I had to create app.d.ts and add this line: /// <reference types="nativewind/types" />

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

No branches or pull requests

3 participants