Code Monkey home page Code Monkey logo

Comments (10)

timothymiller avatar timothymiller commented on May 20, 2024 1

@darthwade This was originally set, it must have been removed by a recent PR.

I added it back so other people don't experience this. Thanks for debugging!

from t4-app.

darthwade avatar darthwade commented on May 20, 2024

Btw, during deployment I also encountered "Error: Could not access built-in Node.js modules. Please make sure that your Cloudflare Pages project has the 'nodejs_compat' compatibility flag set."

adding node_compat to wrangler.toml didn't help, but applying node_compat via CF dashboard helped

[env.preview]
name = "zeus-web-preview"
workers_dev = true
node_compat = true
compatibility_flags = [ "nodejs_compat" ]

[env.production]
name = "zeus-web"
route = "zeus-3v5.pages.dev/*"
workers_dev = false
node_compat = true
compatibility_flags = [ "nodejs_compat" ]

from t4-app.

timothymiller avatar timothymiller commented on May 20, 2024

Yep you have to set node_compat via the CF dashboard. I'm open to solutions that make that process programatic.

Do you have optimizeCSS set in next.config.js? Turn it off if you do.

from t4-app.

darthwade avatar darthwade commented on May 20, 2024
image disabled

from t4-app.

timothymiller avatar timothymiller commented on May 20, 2024

That's strange. Ensure your fork is up to date with the main branch and re-deploy.

from t4-app.

darthwade avatar darthwade commented on May 20, 2024

will do, I created it yesterday via pnpm create t4-app, locally looks good

from t4-app.

darthwade avatar darthwade commented on May 20, 2024

Updated to latest version from main branch, so probably there's some problem during building or deployment/cf configuration
https://zeus-3v5.pages.dev

from t4-app.

timothymiller avatar timothymiller commented on May 20, 2024

Make sure your CF deployment is set to node 18!

from t4-app.

darthwade avatar darthwade commented on May 20, 2024

Strange, recreated cf project from scratch with NODE_VERSION 18 env var, but still same problem https://zeus-web.pages.dev
image

from t4-app.

darthwade avatar darthwade commented on May 20, 2024

After adding TAMAGUI_TARGET=web it finally works :)
@timothymiller thanks for help!

"dev": "TAMAGUI_TARGET=web pnpm with-env next dev",
"build": "TAMAGUI_TARGET=web pnpm with-env next build",
"start": "TAMAGUI_TARGET=web pnpm with-env next start",

from t4-app.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.