** NOTE: ** All component development is based on a template project created by
weex-toolkit
.
$ npm install weex-toolkit -g
If you have any problem while install the weex-toolkit
, you can see the FAQ or issues here
[1] weex-toolkit FAQ
[2] issues
You can run weex plugin create
to create a plugin project
$ weex plugin create [projectname]
The resulting file structure is as follows:
├── android (Plugin folder for Android)
│ ├── library (Module folder for Android plugin,should be include into the examples)
├── ios (Plugin folder for iOS)
├── src (Plugin folder for Web or other custom logic)
├── configs (develop scripts)
├── playground (A playground demo)
│ ├── android (Android demo, default include the plugin module)
│ ├── ios (iOS demo, default include the plugin module)
│ ├── browser (Browser demo, default include the plugin module)
├── examples (Written by vue examples)
├── package.json (npm pulish file, need to be config before publish)
├── README.md
├── webpack.config.js
├── package.json
After the project is created, you can run the npm start
to start your project.
How to devloping web plugin | How to devloping android plugin | How to devloping ios plugin
Step1: Release ios/android
plug-in package to pod and maven warehouse
Cocopod release reference [1] Specs and the Specs Repo [2] Getting setup with Trunk
Maven release reference [1] How to publishing maven artifacts [2] Guide to uploading artifacts to the Central Repository
Step1: Configuration package.json
file as follows before release npm package:
{
"name": "weex-plugin-lottie",
"version": "0.0.1",
...
"web":{
"name":"weex-plugin-lottie",
"version":"0.1.0" // optional
},
"android": {
"groupId": "org.weex.plugin",
"name": "weex-plugin-lottie",
"version": "0.0.1",
// or
"dependency": "org.weex.plugin:weex-plugin-lottie:0.0.1"
},
"ios": {
"name": "weex-plugin-lottie",
"version": "0.0.1"
}
...
}
Tips: the useless comment need to be removed.
processing...
$ weex plugin add weex-plugin-lottie