python+flask+vue开发(3)--vue创建使用

ぃ、小莉子 提交于 2020-03-01 08:24:43

参见:Vue2.0 新手入门 — 从环境搭建到发布

1、创建项目
    在cmd里输入:

cd my_projects\flask_vue

vue init webpack  frontend 

? Project name frontend
? Project description A Vue.js project
? Author 
? Vue build standalone
? Install vue-router? Yes
? Use ESLint to lint your code? Yes
? Pick an ESLint preset Standard
? Set up unit tests No
? Setup e2e tests with Nightwatch? No
? Should we run `npm install` for you after the project has been created? (recommended) npm

 

2、安装依赖

    在cmd里  1).输入:cd frontend (项目名),回车,进入到具体项目文件夹

                    2).输入:cnpm install,回车,等待一小会儿,会发现项目结构里,多了一个

                    node_modules文件夹,这里面都是项目的依赖文件。

                    3).输入:cnpm run dev ,回车运行项目

                    4).输入:cnpm run build ,构建项目

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!