![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
wii-wxapp-cli
Advanced tools
微信小程序脚手架
微信小程序脚手架可以用来快速搭建小程序框架,初始化小程序框架所需要的基本目录,同时可以用来拉取和更新公共组件和公共库,增强代码的可维护性,提高开发效率。
npm install wii-wxapp-cli -g
初始化小程序
进入到项目目录中,执行wxapp init会自动在当前目录下生成对应的基本目录,同时,会自动初始化git,生成.git文件夹
wxapp init
创建模块
创建模块会自动创建对应xxx目录以及该目录下的xxx.js、xxx.wxml、xxx.wxss、xxx.json文件,同时会在app.json中进行页面注册,需在项目根目录下执行此命令
wxapp -p 模块名
拉取/更新公共库
拉取平台组提供的公共库utils,需在项目根目录下执行此命令
wxapp pull utils
拉取/更新公共组件
拉取平台组提供的公共组件components,可根据命令行提示按需拉取某个组件或全部组件,需在项目根目录下执行此命令
wxapp pull components
提交公共库修改
公共库维护者在项目中修改库后可直接将修改提交到公共库
cd utils
wxapp push utils <提交日志>
或者
cd utils
按照常规的git操作进行代码提交
提交公共组件修改
公共组件维护者在项目中修改组件后可直接将修改提交到公共组件
cd components/xxx
wxapp push components <提交日志>
或者
cd components/xxx
按照常规的git操作进行代码提交
wxapp -V
1.克隆带有公共组件和公共库的仓库
git clone <url> --recursive
2.修改子组件的HEADER文件,将其指向master分支,参考http://mobile.51cto.com/aprogram-393324.htm
git submodule foreach git checkout master
1.创建文件夹
mkdir xProject
2.初始化小程序代码
cd xProject
wxapp init
3.拉取小程序公共库
wxapp pull utils
4.按需拉取小程序公共组件
wxapp pull components
5.关联到远程仓库
git remote add origin <url>
6.发布到远程仓库
git add/commit/push
1.进入项目根目录
2.git submodule foreach git pull
conf.js是小程序的域名、部分接口配置文件,在小程序初始化时配置。 为了避免将域名、登录等接口通过脚手架的形式暴露出去,同时提供请求、登录等模块的封装,我们将部分项目相关的敏感信息放入conf.js。
FAQs
微信小程序脚手架功能完善-增加wiiui
The npm package wii-wxapp-cli receives a total of 7 weekly downloads. As such, wii-wxapp-cli popularity was classified as not popular.
We found that wii-wxapp-cli demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.