Giter Site home page Giter Site logo

Comments (4)

c12i avatar c12i commented on May 31, 2024 1

So you're saying that only when using a built-in template the scaffolding tool should prompt to ask about which particular package manager to use?

Yes, only for built in templates. For custom templates, the choice would be pre-determined by the author, therefore the user would not get prompted while using one.

from scaffolding.

guillemcordoba avatar guillemcordoba commented on May 31, 2024

Hum I don't actually have this experience. The custom template https://github.com/holochain-open-dev/templates uses pnpm as its package manager, and everything works just fine. What's more, pnpm is the only package I want users from my template to be able to use, as it has a unique and essential feature for my modules pattern.

I don't think the internal code from the scaffolding tool actually assumes npm at all, so the custom templates can add the one they want. Actually if they even wanted they could write their UIs with rust using something like yew, and I think this is still supported using a custom template, and not modifying anything from the source code of the scaffolding tool.

from scaffolding.

c12i avatar c12i commented on May 31, 2024

I believe the scaffolding tool implicitly assumes the use of npm based on the following observations:

  1. The scaffolding instructions explicitly recommend using npm to install dependencies when setting up a web app. For reference, see this specific line in the cli code.
  2. The package.json file within the web app's root directory contains scripts that invoke npm commands that run a workspace member's scripts. For example, look at this script here. The APIs for managing workspaces vary significantly among package managers, which suggests a reliance on npm's specific features. As a result, using alternative package managers like yarn or pnpm might necessitate manual script adjustments post-scaffolding.

This issue is particularly relevant to the inbuilt templates. While custom templates can specify their preferred package/build managers, the cli should not prompt users to choose a package manager in those cases.

from scaffolding.

guillemcordoba avatar guillemcordoba commented on May 31, 2024

Ah sure yeah, I'm happy to admit that the built-in templates have a total reliance on npm, but that can be totally overriden by using a custom template. The line of code in the instructions can also be overriden in a custom template, but I admit it's true that that indicates a preference towards npm.

So you're saying that only when using a built-in template the scaffolding tool should prompt to ask about which particular package manager to use? What about custom templates then? Some of them would support different package managers, some of them only one, while other won't even have any UI...

from scaffolding.

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.