Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Proposal] nano-jsx cli to provide better developer experience. #80

Open
Shinyaigeek opened this issue Dec 11, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@Shinyaigeek
Copy link
Contributor

Motivation 🔥

Currently, mastering nano-jsx is a difficult task for a beginner web developer (I am not going to offend you).

To improve this situation, How about nano-jsx providing a cli?

Cli’s feature (?)

  • easier setup: nano-jsx create [APP]
    • nano-jsx create should only handle a very simple setup. I think a more detailed setup to ask questions by dialog should be done with create-nano-jsx-app
  • easier serve: nano-jsx serve with express6
  • earsier build: nano-jsx build
  • easier dev server: nano-jsx start or nano-jsx dev
  • earsier deploy: nano-jsx deploy with "Node.js & vercel" or "deno & Deno Deploy”
  • and more (docs, info, help)

How about do you think about this? If it looks good, I want to start to work on this little by little.

@yandeu
Copy link
Member

yandeu commented Dec 13, 2021

In my opinion all these command are a bit too high level for a nanojsx cli.

Everyone should use the style he prefers.


I can imagine adding simple low level elements like:

  • nano-jsx server --express6 --cjs /server/server.tsx
  • nano-jsx component /shared/components/button.tsx
  • nano-jsx page /shared/pages/home.tsx
  • nano-jsx router /shared/component/router.tsx
  • nano-jsx routes /shared/component/navigation.tsx
  • nano-jsx hydrate /client/hydrate/main.tsx

See: https://github.com/nanojsx/nano/tree/cli

@Shinyaigeek
Copy link
Contributor Author

Well, I think it's a good idea to provide low layer functionality to help with initialization. It seems good that a third-party library uses it to provide some high layer functionality

@yandeu yandeu added the enhancement New feature or request label Dec 14, 2021
@hbroer
Copy link

hbroer commented Aug 23, 2023

If you still think about this, I would suggest only to provide starter templates and simple configurations. The problem that I have with CLIs like react-create-app is that beginners don't learn how to setup the project and then depend on that tools. Refactoring out the "hidden magic" of CLI tools to get a project configuration to an explicit, actual and custom configurable state can even for experienced devs be a pain. It also is a problem in case of flexibility. I for example use Microbundle (Libs and WebComponents) and Webpack (SPAs) depending on the context of the project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants