工欲善其事必先利其器

ide安装、配置】

https://tencent.github.io/wepy/document.html

  • VS Code

  1. 在 Code 里先安装 Vue 的语法高亮插件 Vetur

  2. 打开任意 .wpy 文件。

  3. 点击右下角的选择语言模式,默认为纯文本

  4. 在弹出的窗口中选择 .wpy 的配置文件关联...

  5. 在选择要与 .wpy 关联的语言模式 中选择 Vue

监听文件改动】

$ wepy build --watch
[19:36:01] [编译] 入口: src\app.wpy
[19:36:02] [写入] JSON: dist\app.json
[19:36:02] [编译] 组件: src\components\counter.wpy
[19:36:02] [编译] 组件: src\components\group.wpy
[19:36:03] [编译] 组件: src\components\groupitem.wpy
[19:36:03] [编译] 组件: src\components\list.wpy
[19:36:03] [编译] 组件: src\components\panel.wpy
[19:36:03] [编译] 组件: src\components\wepy-list.wpy
[19:36:03] [拷贝] HTML: src\index.template.html
[19:36:03] [编译] 页面: src\pages\index.wpy
[19:36:03] [写入] JSON: dist\pages\index.json
[19:36:03] [写入] JS : dist\app.js
[19:36:03] [写入] JS : dist\components\counter.js
[19:36:03] [写入] JS : dist\components\group.js
[19:36:03] [写入] JS : dist\components\groupitem.js
[19:36:03] [写入] JS : dist\components\list.js
[19:36:03] [写入] JS : dist\components\panel.js
[19:36:03] [写入] JS : dist\components\wepy-list.js
[19:36:03] [写入] JS : dist\mixins\test.js
[19:36:03] [写入] WXML: dist\pages\index.wxml
[19:36:03] [写入] JS : dist\pages\index.js
[19:36:04] [写入] JS : dist\store\actions\counter.js
[19:36:04] [写入] JS : dist\store\actions\index.js
[19:36:04] [写入] JS : dist\store\index.js
[19:36:04] [写入] JS : dist\store\reducers\counter.js
[19:36:04] [写入] JS : dist\store\reducers\index.js
[19:36:04] [写入] JS : dist\store\types\counter.js
[19:36:04] [写入] JS : dist\store\types\index.js
[19:36:04] [写入] WXSS: dist\app.wxss
[19:36:04] [写入] WXSS: dist\components\counter.wxss
[19:36:04] [写入] WXSS: dist\components\group.wxss
[19:36:04] [写入] WXSS: dist\components\groupitem.wxss
[19:36:04] [写入] WXSS: dist\components\list.wxss
[19:36:04] [写入] WXSS: dist\components\panel.wxss
[19:36:04] [写入] WXSS: dist\components\wepy-list.wxss
[19:36:04] [写入] WXSS: dist\pages\index.wxss
[19:36:04] [信息] 开始监听文件改动。

项目根目录】

$ pwd
/d/wepyAction/new

Administrator@PC-20160727BOAG MINGW64 /d/wepyAction/new
$ ll -as
total 238
4 drwxr-xr-x 1 Administrator 197121 0 八月 23 19:02 ./
0 drwxr-xr-x 1 Administrator 197121 0 八月 23 18:52 ../
1 -rw-r--r-- 1 Administrator 197121 147 八月 23 18:52 .editorconfig
1 -rw-r--r-- 1 Administrator 197121 7 八月 23 18:52 .eslintignore
4 -rw-r--r-- 1 Administrator 197121 694 八月 23 18:52 .eslintrc.js
1 -rw-r--r-- 1 Administrator 197121 28 八月 23 18:52 .gitignore
1 -rw-r--r-- 1 Administrator 197121 26 八月 23 18:52 .prettierrc
8 -rw-r--r-- 1 Administrator 197121 6324 八月 23 19:02 .wepycache
1 -rw-r--r-- 1 Administrator 197121 46 八月 23 18:52 .wepyignore
4 drwxr-xr-x 1 Administrator 197121 0 八月 23 19:02 dist/
96 drwxr-xr-x 1 Administrator 197121 0 八月 23 19:00 node_modules/
4 -rw-r--r-- 1 Administrator 197121 1488 八月 23 18:52 package.json
104 -rw-r--r-- 1 Administrator 197121 105067 八月 23 19:00 package-lock.json
1 -rw-r--r-- 1 Administrator 197121 290 八月 23 19:04 project.config.json
4 drwxr-xr-x 1 Administrator 197121 0 八月 23 18:52 src/
4 -rw-r--r-- 1 Administrator 197121 1400 八月 23 18:52 wepy.config.js

依此打开微信开发者工具预览效果和编辑器建立项目

】s

wepy开发的更多相关文章

  1. 微信小程序wepy开发循环wx:for需要注意

    微信小程序wepy开发循环wx:for需要注意 item index值必须在wx:for之后使用 <view wx:for="{{tablist}}" class=" ...

  2. wepy开发小程序eslint报错error 'getApp' is not defined no-undef

    wepy开发小程序使用getApp().globalData保存全局数据很方便,但是会在控制台看到很多报错:“error 'getApp' is not defined no-undef”,这是esl ...

  3. 使用wepy开发微信小程序商城第三篇:购物车(布局篇)

    使用wepy开发微信小程序商城 第三篇:购物车(布局篇) 前两篇如下: 使用wepy开发微信小程序商城第一篇:项目初始化 使用wepy开发微信小程序商城第二篇:路由配置和页面结构 基于上两篇内容,开始 ...

  4. 使用wepy开发微信小程序商城第二篇:路由配置和页面结构

    使用wepy开发微信小程序商城 第二篇:路由配置和页面结构 前言: 最近公司在做一个微信小程序的项目,用的是类似于vue的wepy框架.我也借此机会学习和实践一下. 小程序官方文档:https://d ...

  5. 使用wepy开发微信小程序商城第一篇:项目初始化

    使用wepy开发微信小程序商城 第一篇:项目初始化 前言: wepy小程序项目初始化的操作,官方文档看了好几遍,感觉写得不是很清楚. 这篇写得挺好的:小程序开发之wepy 1.初始化项目 (1)全局安 ...

  6. 《微信小程序项目开发实战:用WePY、mpvue、Taro打造高效的小程序》(笔记1)WePY开发环境的安装

    WePY的安装或更新都通过npm进行,全局安装或更新WePY命令行工具,使用以下命令: npm install wepy-cli -g 稍等片刻,成功安装后,即可创建WePY项目. 注意:如果npm安 ...

  7. WePY开发环境的安装和小程序生成WePY项目

    相对于微信开发者工具而言,WePY的安装和生成项目稍显复杂.特记录下安装顺序: 1.安装Node.js 在Node官网(https://nodejs.org/)下载Node.js的安装包,此处我下载的 ...

  8. 使用wepy开发微信小程序01——常用的组件

    1.axio.js 'use strict' import axios from 'axios' import wepyAxiosAdapter from 'wepy-plugin-axios/dis ...

  9. 微信小程序wepy开发,属性绑定的事件参数中可以使用{{}}写实参

    <view wx:for="{{tablist}}" class="item {{activeid === item.id ? 'active':''}}" ...

随机推荐

  1. Enable and Use Remote Commands in Windows PowerShell

    The Windows PowerShell remoting features are supported by the WS-Management protocol and the Windows ...

  2. ie下table无法设置宽度的坑,解决方案:在td里面添加div把td宽度撑开即可。

    <td><div style="width:180px"> <a data-b="2" class="btn btn-s ...

  3. 解决使用webbrowser请求url时数据传递丢失问题

    问题: 使用“ this.webBrowser.Url = new Uri(webBrowserUrl);”方式请求Action(Java Web)并传递数据,在webBrowserUrl中携带的参数 ...

  4. 快充 IC BQ25896 的 ICO (input current optimizer)

    ICO (input current optimizer) 手機接上 adapter 後, 手機裡的 charger IC bq25896 開始向 adapter 抽取 current 供給 batt ...

  5. Struts2的上传与下载

    转自:http://blog.csdn.net/Mark_LQ/article/details/49822821 10.1.1 文件上传基本案例   第一步:上传组件依赖与commons-fileup ...

  6. npm 查看模块全部版本

    npm 查看模块全部版本:(jquery) npm view jquery versions 安装指定版本: (jquery) npm install jquery@1.7.2

  7. Oracle单个datafile大小的限制

    http://blog.itpub.net/30776559/viewspace-2146790/

  8. vSphere Client 更改 ESX/ESXi 主机的端口

    https://blog.csdn.net/hanzheng260561728/article/details/51283808?locationNum=8&fps=1

  9. remove xcode recent projects from dock menu 移除xcode dock菜单显示的项目列表

    Launch Xcode Select File->Open Recent->Clear Menu Right-click the Xcode icon and select Show A ...

  10. 实践认识--ANN

    1. 常用激活函数  激活函数的选择是构建神经网络过程中的重要环节,下面简要介绍常用的激活函数. (1) 线性函数 ( Liner Function ) (2) 斜面函数 ( Ramp Functio ...