gluestack / gluestack-ui-starter-kits

https://universal-starter-kit.gluestack.io/
64 stars 11 forks source link

Any reason for yarn vs pnpm? #25

Closed shawnmclean closed 1 month ago

shawnmclean commented 2 months ago

The react-native-css-interop patch doesn't work when using pnpm for some reason.

shawnmclean commented 2 months ago

Update:

patch-package works (not using built in pnpm patch behavior.

Project runs now, styles are rendered. Figuring out an issue with /profile now.

Import trace for requested module:
../../node_modules/@expo/html-elements/build/elements/Anchor.js
../../node_modules/@expo/html-elements/build/Elements.js
../../packages/components/ui/select/select-actionsheet.tsx
../../packages/components/ui/select/index.tsx
../../packages/screens/profile-screens/profile/index.tsx
./app/profile/profile/page.tsx
 ⨯ ../../node_modules/@expo/html-elements/build/elements/Anchor.js
Module parse failed: Unexpected token (23:11)
|         },
|     });
>     return <Text role="link" {...props} {...nativeProps} ref={ref}/>;
| });
| //# sourceMappingURL=Anchor.js.map

Import trace for requested module:
../../node_modules/@expo/html-elements/build/elements/Anchor.js
../../node_modules/@expo/html-elements/build/Elements.js
../../packages/components/ui/select/select-actionsheet.tsx
../../packages/components/ui/select/index.tsx
../../packages/screens/profile-screens/profile/index.tsx
./app/profile/profile/page.tsx
shawnmclean commented 1 month ago

Using pnpm causes an error with react-native-svg:

 ../../node_modules/@react-native/assets-registry/registry.js
Module parse failed: Unexpected token (13:7)
| 'use strict';
|
> export type PackagerAsset = {
|   +__packager_asset: boolean,
|   +fileSystemLocation: string,

Import trace for requested module:
../../node_modules/@react-native/assets-registry/registry.js
../../node_modules/react-native-svg/lib/module/lib/resolveAssetUri.js
../../node_modules/react-native-svg/lib/module/web/utils/prepare.js
../../node_modules/react-native-svg/lib/module/web/WebShape.js
../../node_modules/react-native-svg/lib/module/elements.web.js
../../node_modules/react-native-svg/lib/module/ReactNativeSVG.web.js
../../node_modules/react-native-svg/lib/module/index.js
../../packages/components/ui/button/index.tsx
./app/page.tsx
shawnmclean commented 1 month ago

Solved by locking the dependencies.

Migration example here: https://github.com/shawnmclean/sovoli/pull/23