GithubHelp home page GithubHelp logo

Comments (6)

ervwalter avatar ervwalter commented on August 10, 2024

I noticed the same. It's because the snowpack.config.js in @snowpack/app-scripts-svelte specifies a build script for .js files that looks like:

"build:js": "cat"

But there is no cat executable on windows. My workaround was to run npm start and/or npm build from a Git Bash prompt instead of from the Windows command prompt because Git Bash adds basic unix tools like cat to the path.

Maybe the template should install and use the cat npm module since that appears to be cross platform.

from create-snowpack-app.

ervwalter avatar ervwalter commented on August 10, 2024

FYI, I did npm install cat in my sample project made from the template and it started working because that npm module installs a cat command in node_modules.

from create-snowpack-app.

FredKSchott avatar FredKSchott commented on August 10, 2024

Didn't even think of this! Could be smart to just add this as a dependency to the app-scripts package by default

from create-snowpack-app.

FredKSchott avatar FredKSchott commented on August 10, 2024

Update: With the way we're going, cat may just end up being the default behavior: If no build script is defined, assume it's okay to just copy over. In that case, we could just remove cat and solve this problem by ignoring it (for now, anyway)

from create-snowpack-app.

FredKSchott avatar FredKSchott commented on August 10, 2024

Fixed: files without a build script are now copied by default. This has been true for a while, but we are now also handling JS imports properly as well for JS files, with or without a 'build:js' script.

you can remove 'cat' from your build scripts (we're removing them now from the CSA apps) and this should solve this problem.

if you run into this problem later on in your own scripts, you can check out: https://github.com/shelljs/shx

from create-snowpack-app.

countnazgul avatar countnazgul commented on August 10, 2024

Thank you very much guys!

from create-snowpack-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.