当前位置:网站首页>Analysis of CCB small program development tool chain principle

Analysis of CCB small program development tool chain principle

2020-12-06 15:15:56 InfoQ

{"type":"doc","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":" stay "},{"type":"link","attrs":{"href":"http:\/\/mp.weixin.qq.com\/s?__biz=MzI5NDE3ODQyNg==&mid=2247502687&idx=1&sn=2008d5b0a5651be9b1520c83110b2cf6&chksm=ec64504adb13d95cc6017ce473912b7217444a1f461bcdd8dda7ceaec74b25be0645407438e1&scene=21#wechat_redirect","title":"","type":null},"content":[{"type":"text","text":"《 First knowledge of CCB applet engine 》"}]},{"type":"text","text":" In this article we learn that , CCB applet is a new way to connect users and services , It can be easily obtained and disseminated in CCB application , At the same time, it has a good user experience . General development tools , There will be a development tool chain for users . that , What is the principle of CCB small program development tool chain ? This article will introduce the above contents ."}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":" notes : This article is based on @jump-mp\/cli The version is 1.2.6"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":2},"content":[{"type":"text","text":" Development tool chain "}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"@jump-mp\/cli Please refer to CCB applet development document for details of installation and use method ."}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":" Run at terminal "}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"codeblock","attrs":{"lang":"text"},"content":[{"type":"text","text":"`$ jump -h`\n"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":" You can see @jump-mp\/cli Provides the following functions :"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"codeblock","attrs":{"lang":"java"},"content":[{"type":"text","text":"1. `Usage: jump [options]`\n2. \n3. `Options:`\n4. ` **-v, --version** output the version number`\n5. ` **-h, --help** display help for command`\n6. \n7. `Commands:`\n8. ` **init** initialize template for jump project`\n9. ` **build [options]** build project to be used in android or ios`\n10. ` **update** update project dependencies to the latest version`\n11. ` **add [options] ** add npm source for miniproject`\n12. ` **construct** construct installed npm source for miniproject`\n13. ` **help [command]** display help for command`\n\n"}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"bulletedlist","content":[{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"init: Initialization method , Used to initialize applet projects and pages 、 Components ;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"build: Used to compile and package CCB applet ;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"update: Used to update the dependent version used by CCB applet ;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"add: Used to add applet dependencies ;"}]}]},{"type":"listitem","attrs":{"listStyle":null},"content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"construct: Used to build dependencies added by applets ."}]}]}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":2},"content":[{"type":"text","text":" Scaffold principle "}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":" In the last section , It has been introduced that "},{"type":"codeinline","content":[{"type":"text","text":"@jump-mp\/cli "}]},{"type":"text","text":" Basic functions of . This section will focus on scaffolding "},{"type":"codeinline","content":[{"type":"text","text":"@jump-mp\/cli "}]},{"type":"text","text":" This paper introduces the overall architecture and technology selection of ."}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":3},"content":[{"type":"text","text":" Analysis of existing scaffold technology "}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":" At present, the more commonly used front-end development scaffold tools are "},{"type":"codeinline","content":[{"type":"text","text":"yoeman"}]},{"type":"text","text":"、"},{"type":"codeinline","content":[{"type":"text","text":"vue-cli "}]},{"type":"text","text":" etc. ."}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"codeinline","content":[{"type":"text","text":"yeoman "}]},{"type":"text","text":" Build projects need to provide "},{"type":"codeinline","content":[{"type":"text","text":"yoeman-generator"}]},{"type":"text","text":"."},{"type":"codeinline","content":[{"type":"text","text":"yoeman-generator "}]},{"type":"text","text":" In essence, there is i Project templates with complete file structure , Users need to manually put these "},{"type":"codeinline","content":[{"type":"text","text":"generator "}]},{"type":"text","text":" Download to local , then "},{"type":"codeinline","content":[{"type":"text","text":"yoeman "}]},{"type":"text","text":" Based on this "},{"type":"codeinline","content":[{"type":"text","text":"generator "}]},{"type":"text","text":" Automatically generate a variety of different projects ."}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"codeinline","content":[{"type":"text","text":"vue-cli "}]},{"type":"text","text":" Provides a wealth of options and settings , But its essence is to pull different templates from remote warehouse to local , It is not. “ Locally generated “ The black science and technology ."}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":" Sum up , At present, the idea of scaffold is to establish different model projects , Then the scaffold refers to the template project according to the user instructions to generate the actual project . Sample projects can be built into scaffolding , It can also be deployed in remote warehouses ."}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":3},"content":[{"type":"text","text":" Technology selection and Architecture "}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}}]}

版权声明
本文为[InfoQ]所创,转载请带上原文链接,感谢
https://chowdera.com/2020/12/202012061513501677.html