vscode作为一个轻量级编辑器,有其独特的魅力。
- 安装Ionic:npm install -g ionic
- 安装Apache Ripple模拟器: npm install -g ripple-emulator
- 生成Ionic项目:
$ ionic start myApp [blank|tabs|sidemenu]
$ ionic start myApp tabs
- 添加平台
cordova build --release android
- 用VsCode打开myApp
- 设置tasks:
{ "version": "0.1.0", "command": "ripple", "isShellCommand": true, "showOutput": "always", "args": ["emulate","--path","c:\Users\Administrator\myApp\www"] }
- ctrl+shift+b:启动ripple模拟器预览myapp