Closed LucasMERN closed 2 weeks ago
Unusual as I’m typically using it from newer versions (on macOS). Are you on windows?
Yes I am. I've seen it reported in 2 of the other issues that were open recently as well. https://github.com/mattdesl/canvas-sketch/issues/201#issuecomment-2265187355
I've just changed a feature that may help. Unfortunately I don't have access to Windows right now.
Can you try updating the CLI?
If you are using it globally:
npm i canvas-sketch-cli@1.15.0 --global
mkdir test-sketch
cd test-sketch
canvas-sketch sketch.js --new
Or if you are using it with npx
:
mkdir test-sketch
cd test-sketch
npx canvas-sketch-cli@1.15.0 sketch.js --new
Or if you are using it with locally installed devDependency:
mkdir test-sketch
cd test-sketch
npm init -y
npm install canvas-sketch-cli@1.15.0 --save-dev
npx canvas-sketch sketch.js --new
Works now. You can reclose this thread. I commented back on another thread.
I've tried it with 18 and 20. both will seem to install the CLI but the commands do not work. This is not a huge deal as anyone can use nvm to switch back and forth but you will not be able to create a new project with Astro, Next, Vite, and probably others without Node 18+.