当前位置:网站首页>Harmonyos JS demo application development
Harmonyos JS demo application development
2022-07-06 13:58:00 【Big 1234 grass】
List of articles
Preface
Under the experience "HarmonyOS JS Demo application development ".
Video tutorial :HarmonyOS JS Demo application development
Source warehouse :harmonyos_app_samples
Not yet HarmonyOS Structural understanding , If you need to know , You can refer to Official documents .
In the link above demo, From the perspective of application developers , In general :html According to the content ,css Control style ,JavaScript For interactive .
Because the warehouse code uses Apache License 2.0, It can be copied here / Modify some codes in the warehouse for notes , See warehouse for complete code .
brief introduction :
This example is suitable for introducing how to develop a JS Demo application .
This application is shown by an example of a list JS Interface layout and logic implementation in the process of application development .
Show the list of schedules on the application page , The list item consists of the item name 、 Time 、 The degree of urgency consists of . It supports checking and deleting the event list .
matters needing attention
The code is easy to understand . Here we just look at how one element in the list is laid out .
Because my front end is more delicious , So here's the layout .
html The code is as follows :
<div class="container">
<text class="title">
{
{ $t('strings.hello') }} {
{ title }}
</text>
<list>
<list-item for="{
{todayList}}" class="todo-list-item">
<image class="todo-image-left" src="{
{$item.checkBtn}}" onclick="completeEvent({
{$item.id}})"></image>
<div class="todo-item flex-row">
<div class="todo-name-mark">
<text class="todo-name">{
{$item.event}}</text>
<text class="todo-mark {
{$item.tag}}"></text>
</div>
<text class="todo-time">{
{$item.time}}</text>
</div>
<image class="todo-image-right" src="/common/images/delete.png" onclick="deleteEvent({
{$item.id}})" show="{
{$item.completeState}}"></image>
</list-item>
</list>
</div>
The effect is as follows :
[1] " Appointment "event and " Small yellow dot "tag In a div
( It's called div1 Well ) in .
[2] "14:30"time and div1, In the larger div2( It's called div2 Well ) in . Use Flex Layout up and down .
[3] ️、 and div2, For one list-item.
边栏推荐
- 7-9 制作门牌号3.0(PTA程序设计)
- Miscellaneous talk on May 27
- Leetcode. 3. Longest substring without repeated characters - more than 100% solution
- Experiment 7 use of common classes
- 强化学习系列(一):基本原理和概念
- 自定义RPC项目——常见问题及详解(注册中心)
- UGUI—Text
- (original) make an electronic clock with LCD1602 display to display the current time on the LCD. The display format is "hour: minute: Second: second". There are four function keys K1 ~ K4, and the fun
- [modern Chinese history] Chapter V test
- .Xmind文件如何上传金山文档共享在线编辑?
猜你喜欢
2022 Teddy cup data mining challenge question C idea and post game summary
Nuxtjs快速上手(Nuxt2)
7-7 7003 combination lock (PTA program design)
仿牛客技术博客项目常见问题及解答(二)
FAQs and answers to the imitation Niuke technology blog project (II)
Principles, advantages and disadvantages of two persistence mechanisms RDB and AOF of redis
自定义RPC项目——常见问题及详解(注册中心)
HackMyvm靶机系列(3)-visions
Renforcer les dossiers de base de l'apprentissage
Leetcode.3 无重复字符的最长子串——超过100%的解法
随机推荐
[the Nine Yang Manual] 2020 Fudan University Applied Statistics real problem + analysis
中间件漏洞复现—apache
UGUI—Text
强化學習基礎記錄
HackMyvm靶机系列(2)-warrior
About the parental delegation mechanism and the process of class loading
Relationship between hashcode() and equals()
7-8 7104 Joseph problem (PTA program design)
[three paradigms of database] you can understand it at a glance
Package bedding of components
Yugu p1012 spelling +p1019 word Solitaire (string)
[during the interview] - how can I explain the mechanism of TCP to achieve reliable transmission
7-7 7003 组合锁(PTA程序设计)
[hand tearing code] single case mode and producer / consumer mode
HackMyvm靶机系列(3)-visions
. Net6: develop modern 3D industrial software based on WPF (2)
HackMyvm靶机系列(7)-Tron
Strengthen basic learning records
【数据库 三大范式】一看就懂
Hackmyvm Target Series (3) - vues