Go to the folder where the project will be stored (note that you run cmd as an administrator. If you use powershell, you need to set a security policy)
1. Create a project named fileproject01
vue create fileproject01
2. Scaffolding plug-in selection
- Select the third option: manually select features: manually select features
Option selection: Use arrows to select
>
the default vue2 template, which contains the babel plug-in and eslint plug-in
>
. The default vue3 template includes the babel plug-in and eslint plug-in
>
manual options.
- The manual options are: babel (ES6 to ES5 tool), router (routing), Vuex. Do not install other plug-ins first, you can install them manually when you need them later. (Press the space bar to select or cancel the selection, and press Enter after completing the selection)
? Please make a selection: Manual option
? Check the functions required for the project: (Press<space>
Select,<a>
switch all,<i>
invert selection)
() Select vue version
(*) Syntax high and low version converter plug-in (convert high version syntax to low version syntax )
( ) Style plug-in
( ) Plug-in that packages programs into small programs
( * ) Routing plug-in
( * ) Vuex
( ) CSS style preprocessing plug-in
( ) Code formatting plug-in
( ) Unit test
( ) End-to-end test
- Plug-in option selection
Next step select the vue version, here choosevue2
.
Here choose
whether package.json uses the current project as a template for future project creation: No (n)
- Scaffolding is being built (it takes about 1 minute to wait after entering).
Installation
is complete.
3. Manually enter the project and run it
cd fileproject01
npm run serve
operation result
4. Import Idea
- Open the project in idea and get the vue.js plug-in: file-settings-plugins-vue.js-install
- Set the running shortcut
add configration