Code Monkey home page Code Monkey logo

Comments (8)

rschristian avatar rschristian commented on June 8, 2024 1

Ah, yeah Yarn 2+ isn't likely to be supported. Too niche, too demanding. Would stick to v1 or NPM.

from preact-cli.

rschristian avatar rschristian commented on June 8, 2024 1

It's not so much that it'd need to bail that it's not worth going out of our way to test/support. If it works, then great.

Sorry, but that was just in reference to that create-preact error you shared, haven't looked into this issue here yet.

from preact-cli.

rschristian avatar rschristian commented on June 8, 2024

You'll need to specify what versions of those plugins you're using, but I should point out preact-cli isn't maintained. I might be able to help, but you're best off migrating to more modern tooling.

from preact-cli.

bre7 avatar bre7 commented on June 8, 2024

Oh, had no idea, just starting with preact and was using the default TS template.

Last versions mostly:
https://github.com/bre7/preact-demo1/blob/main/package.json#L24C1-L51C5

If you can spot anything weird, would really appreciate it. Otherwise I'll switch build tooling 🌞.

Thanks for the instant help btw !

from preact-cli.

rschristian avatar rschristian commented on June 8, 2024

Will take a look.

I'd suggest taking a peek at create-preact instead, which we call out on our docs and in this ReadMe:

Note preact-cli no longer sees active development! It's stable so you can rely upon it for all of your existing apps, but for creating new ones, we recommend Vite via create-preact. It's a much faster, more modern experience and we're working to bring some Preact-CLI/WMR features to it.


Oh, had no idea, just starting with preact and was using the default TS template.

Did something point you to Preact-CLI? I'd like to clean up any materials referencing it.

from preact-cli.

bre7 avatar bre7 commented on June 8, 2024

Mmmh, this was how I ended up using cli:

  1. yarn create preact whatever
  2. Q&A based setup
  3. Builds always ended up aborting before finalizing (Resolution βœ…, Fetching βœ…, Linking ❌):

➀ YN0000: β”Œ Link step
➀ YN0000: β”‚ ESM support for PnP uses the experimental loader API and is therefore experimental
➀ YN0007: β”‚ esbuild@npm:0.17.19 must be built because it never has been before or the last one failed
➀ YN0007: β”‚ esbuild@npm:0.18.20 must be built because it never has been before or the last one failed
➀ YN0009: β”‚ esbuild@npm:0.18.20 couldn't be built successfully (exit code 1, logs can be found here: C:\tier-064\AppData\Local\Temp\xfs-379abe50\build.log)
➀ YN0009: β”‚ esbuild@npm:0.17.19 couldn't be built successfully (exit code 1, logs can be found here: C:\tier-064\AppData\Local\Temp\xfs-7b978f41\build.log)
➀ YN0000: β”” Completed in 0s 707ms
➀ YN0000: Failed with errors in 11s 516ms

at makeError (C:\tier-064\AppData\Local\Yarn\Berry\cache\execa-npm-1.0.0-7028e37029-8.zip\node_modules\execa\index.js:174:9)
at C:\tier-064\AppData\Local\Yarn\Berry\cache\execa-npm-1.0.0-7028e37029-8.zip\node_modules\execa\index.js:278:16
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async installDeps (file:///C:/tier-064/AppData/Local/Yarn/Berry/cache/create-preact-npm-0.2.2-3bddf61d30-8.zip/node_modules/create-preact/src/index.js:200:2)
at async useSpinner (file:///C:/tier-064/AppData/Local/Yarn/Berry/cache/create-preact-npm-0.2.2-3bddf61d30-8.zip/node_modules/create-preact/src/index.js:112:2)
at async createPreact (file:///C:/tier-064/AppData/Local/Yarn/Berry/cache/create-preact-npm-0.2.2-3bddf61d30-8.zip/node_modules/create-preact/src/index.js:88:2) {
code: 1,

πŸ” Using yarn 4.0.2

I might've stumbled upon a blog or old repo maybe about using preact-cli and that one worked.

from preact-cli.

bre7 avatar bre7 commented on June 8, 2024

I'd probably add a tiny alert-warning to the docs, recommending users to avoid using yarn 2+ or preact-cli. I'd be glad to send a PR.

Or maybe an abort error when using https://github.com/preactjs/create-preact if yarn 2+ is detected (not entirely sure how to implement it though).

from preact-cli.

bre7 avatar bre7 commented on June 8, 2024

Don't worry, there's no point in looking into a project with outdated tooling. I'm already switching to Vite ! Thanks for the quick help btw !

P.S: Worked like a charm with npm

from preact-cli.

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.