timothymiller / t4-app

Full stack meta-framework for building iOS, Android, and Progressive Web Apps with Tamagui and deploying to Cloudflare.
https://t4stack.com
MIT License
1.49k stars 84 forks source link

bun web fails #122

Closed ishank-s closed 12 months ago

ishank-s commented 12 months ago
❯ bun web
$ cd apps/next && bun run dev
$ bun with-env next dev
$ dotenv -e ../../.env.local -- next dev
 ○ (pwa) PWA support is disabled.
 ○ (pwa) PWA support is disabled.
  ▲ Next.js 13.5.6
  - Local:        http://localhost:3000
  - Environments: .env
  - Experiments (use at your own risk):
     · scrollRestoration
     · forceSwcTransforms

 ✓ Ready in 3.6s

    ➡ [tamagui] built config and components (287ms):

        Config     ./.tamagui/tamagui.config.cjs
        Components ./.tamagui/tamagui-components.config.cjs
             ./.tamagui/t4ui-components.config.cjs

Tamagui failed loading "/Users/ishanks/dev/tamago/apps/next/.tamagui/tamagui.config.cjs"

  Cannot access 'View' before initialization
  /Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:19
  View: () => View
              ^

ReferenceError: Cannot access 'View' before initialization
    at Object.View (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:19:15)
    at Object.get (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:11:88)
    at Object.<anonymous> (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:25:25)
    at Module._compile (node:internal/modules/cjs/loader:1198:14)
    at Module._compile (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2258:26)
    at Module._extensions..js (node:internal/modules/cjs/loader:1252:10)
    at Object.newLoader (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2262:9)
    at Object.extensions..js (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:4838:24)
    at Module.load (node:internal/modules/cjs/loader:1076:32)
    at Function.Module._load (node:internal/modules/cjs/loader:911:12)
    at Module.require (node:internal/modules/cjs/loader:1100:19)
    at Module.mod.require (/Users/ishanks/dev/tamago/node_modules/next/dist/server/require-hook.js:64:28)
    at /Users/ishanks/dev/tamago/node_modules/@tamagui/static/dist/cjs/registerRequire.js:48:88
    at requireTamaguiCore (/Users/ishanks/dev/tamago/node_modules/@tamagui/static/dist/cjs/helpers/requireTamaguiCore.js:23:10)
    at Module.tamaguiRequire [as require] (/Users/ishanks/dev/tamago/node_modules/@tamagui/static/dist/cjs/registerRequire.js:48:63)

Tamagui failed loading "/Users/ishanks/dev/tamago/apps/next/.tamagui/tamagui-components.config.cjs"

  Cannot access 'View' before initialization
  /Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:19
  View: () => View
              ^

ReferenceError: Cannot access 'View' before initialization
    at Object.View (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:19:15)
    at Object.get (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:11:88)
    at Object.<anonymous> (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:25:25)
    at Module._compile (node:internal/modules/cjs/loader:1198:14)
    at Module._compile (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2258:26)
    at Module._extensions..js (node:internal/modules/cjs/loader:1252:10)
    at newLoader (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2262:9)
    at Object.newLoader (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2262:9)
    at Object.extensions..js (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:4838:24)
    at Module.load (node:internal/modules/cjs/loader:1076:32)
    at Function.Module._load (node:internal/modules/cjs/loader:911:12)
    at Module.require (node:internal/modules/cjs/loader:1100:19)
    at Module.mod.require (/Users/ishanks/dev/tamago/node_modules/next/dist/server/require-hook.js:64:28)
    at /Users/ishanks/dev/tamago/node_modules/@tamagui/static/dist/cjs/registerRequire.js:48:88
    at requireTamaguiCore (/Users/ishanks/dev/tamago/node_modules/@tamagui/static/dist/cjs/helpers/requireTamaguiCore.js:23:10)

Tamagui failed loading "/Users/ishanks/dev/tamago/apps/next/.tamagui/t4ui-components.config.cjs"

  Cannot access 'View' before initialization
  /Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:19
  View: () => View
              ^

ReferenceError: Cannot access 'View' before initialization
    at Object.View (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:19:15)
    at Object.get (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:11:88)
    at Object.<anonymous> (/Users/ishanks/dev/tamago/node_modules/@tamagui/core/dist/cjs/index.js:25:25)
    at Module._compile (node:internal/modules/cjs/loader:1198:14)
    at Module._compile (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2258:26)
    at Module._extensions..js (node:internal/modules/cjs/loader:1252:10)
    at newLoader (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2262:9)
    at Object.newLoader (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:2262:9)
    at Object.extensions..js (/Users/ishanks/dev/tamago/node_modules/esbuild-register/dist/node.js:4838:24)
    at Module.load (node:internal/modules/cjs/loader:1076:32)
    at Function.Module._load (node:internal/modules/cjs/loader:911:12)
    at Module.require (node:internal/modules/cjs/loader:1100:19)
    at Module.mod.require (/Users/ishanks/dev/tamago/node_modules/next/dist/server/require-hook.js:64:28)
    at /Users/ishanks/dev/tamago/node_modules/@tamagui/static/dist/cjs/registerRequire.js:48:88
    at requireTamaguiCore (/Users/ishanks/dev/tamago/node_modules/@tamagui/static/dist/cjs/helpers/requireTamaguiCore.js:23:10)

Missing theme, an error occurred when importing your config
Got config: [Function (anonymous)] {
  displayName: 'ProxyWorm - Check excludeReactNativeWebExports',
  _isProxyWorm: true
}
Looking for theme: displayName
ishank-s commented 12 months ago

OS: macOS Bun Version : 1.0.13

cameronrothenburg commented 12 months ago

I have the same issues OS: popOS (Linux) Bun Version: 1.0.7

Branch: Lucia - Copied branch

cameronrothenburg commented 12 months ago

https://github.com/timothymiller/t4-app/issues/111#issuecomment-1817462518 Doing this seems to fix the issue

timothymiller commented 12 months ago

Tamagui version upgrade & bun cachine requries us to run bun clean after updating.