tamagui: Can't start web app when SolitoImage is used by a component
When trying to start the nextjs app with yarn web from the root of the monorepo, I get the following error:
Tamagui Webpack Loader Error:
createCSSVariable expected string: undefined
Error: createCSSVariable expected string: undefined
at createCSSVariable (/home/la/Projects/tamagui-bug/node_modules/@tamagui/core-node/dist/index.js:5838:17)
at variableToCSS (/home/la/Projects/tamagui-bug/node_modules/@tamagui/core-node/dist/index.js:10563:63)
at /home/la/Projects/tamagui-bug/node_modules/@tamagui/core-node/dist/index.js:11016:78
at createTamagui (/home/la/Projects/tamagui-bug/node_modules/@tamagui/core-node/dist/index.js:11086:9)
at loadTamagui (/home/la/Projects/tamagui-bug/node_modules/@tamagui/static/dist/cjs/extractor/loadTamagui.js:155:40)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Object.load [as loadTamagui] (/home/la/Projects/tamagui-bug/node_modules/@tamagui/static/dist/cjs/extractor/createExtractor.js:92:42)
at async extractToClassNames (/home/la/Projects/tamagui-bug/node_modules/@tamagui/static/dist/cjs/extractor/extractToClassNames.js:78:3)
at async Object.loader2 (/home/la/Projects/tamagui-bug/node_modules/tamagui-loader/dist/cjs/loader.js:62:23)
Missing theme, an error occurred when importing your config
Got config: [Function (anonymous)] {
displayName: 'ProxyWorm - Check excludeReactNativeWebExports',
_isProxyWorm: true
}
Looking for theme: displayName
Reproduction
Repo: https://github.com/la55u/tamagui-solitoimage-repro
- run
yarn - run
yarn web - you should see the script exited with the error above
Note that the only thing in the ui package is a simple component that uses SolitoImage. When I try to replace that with any other tamagui component it works. Not sure if this is a tamagui or solito error, but posting it here because it’s included in the starter so it’s expected to work.
Any help would be appreciated, thank you, love Tamagui ❤️
About this issue
- Original URL
- State: closed
- Created a year ago
- Reactions: 3
- Comments: 36 (21 by maintainers)
Hey guys, going to check this out soon
Have a fix for this in the next release.
I have same error with
yarn webas OP when using expo-image. tamagui v1.15.19. Haven’t had the chance to dig much into it yet - just using tamaguiImagefor now which is working.