Skip to content

✨ Create React or Vue project via lean new#505

Merged
jysperm merged 4 commits intonextfrom
lean-new
Mar 29, 2022
Merged

✨ Create React or Vue project via lean new#505
jysperm merged 4 commits intonextfrom
lean-new

Conversation

@jysperm
Copy link
Copy Markdown
Contributor

@jysperm jysperm commented Mar 25, 2022

  • 先选模板再选应用
  • 模板列表的格式从 Express - Node.js 改成 Node.js - Express 这样看上去更整齐

使用 npx 创建 React 或 Vue 的模板和需要的 leanengine.yamlstatic.json 这两个文件,效果大概是:

❯ lean new vue2                                                                                                                                                                                                                                                      
[?] Please select an app template:
 1) Node.js - Express
 2) Node.js - Koa
 3) Python - Flask
 4) Python - Django
 5) Java - Serlvet
 6) Java - Spring Boot
 7) PHP - Slim
 8) .NET Core
 9) Go - Echo
 10) React Web App (via create-react-app)
 11) Vue Web App (via @vue/cli)
 => 11
[?] Please select an app:
 1) test
 => 1
[INFO] Executing `npx @vue/cli create --default --packageManager npm vue2`

Vue CLI v5.0.4
✨  Creating project in /Users/ziting/cli-test/vue2.
🗃  Initializing git repository...
⚙️  Installing CLI plugins. This might take a while...


added 860 packages in 10s
🚀  Invoking generators...
📦  Installing additional dependencies...


added 97 packages in 2s
{
⚓  Running completion hooks...

📄  Generating README.md...

🎉  Successfully created project vue2.
👉  Get started with the following commands:

 $ cd vue2
 $ npm run serve

[INFO] Created Vue Web App (via @vue/cli) project in `vue2`

@jysperm jysperm requested review from cshuaimin, leeyeh and weakish March 25, 2022 07:29
@cshuaimin
Copy link
Copy Markdown
Contributor

cshuaimin commented Mar 25, 2022

Node.js Express 这样看上去更整齐

我是感觉这样前面会有一些相同的语言部分,不利于快速区分。比如我想用 React 写个前端项目,还要想一下 React 用到的语言是什么。

@jysperm
Copy link
Copy Markdown
Contributor Author

jysperm commented Mar 25, 2022

React 确实是这样,但其他后端用户应该很清楚自己要用什么语言吧。我把 Web App 的两个模板的 React 和 Vue 放到了前面,其他后端模板不变。

@leeyeh
Copy link
Copy Markdown
Contributor

leeyeh commented Mar 25, 2022

Vue CLI v5.0.4
✨ Creating project in /Users/ziting/cli-test/vue2.
🗃 Initializing git repository...
⚙️ Installing CLI plugins. This might take a while...

把调用的命令打出来会不会更好一点。

@jysperm
Copy link
Copy Markdown
Contributor Author

jysperm commented Mar 25, 2022

加了打印

[INFO] Executing `npx @vue/cli create --default --packageManager npm vue2`

@jysperm jysperm merged commit 5c98e88 into next Mar 29, 2022
@jysperm jysperm deleted the lean-new branch February 8, 2023 08:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants