jiannibang 4 years ago
commit
822f6b2fc7
  1. 2
      .gitignore
  2. 3
      .mini-ide/project-ide.json
  3. 3
      app.acss
  4. 11
      app.js
  5. 8
      app.json
  6. 3
      mini.project.json
  7. 4
      pages/index/index.axml
  8. 35
      pages/index/index.js
  9. 1
      pages/index/index.json
  10. BIN
      snapshot.png

2
.gitignore

@ -0,0 +1,2 @@
.tea
node_modules

3
.mini-ide/project-ide.json

@ -0,0 +1,3 @@
{
"enableLegacyRemoteDebug": false
}

3
app.acss

@ -0,0 +1,3 @@
page {
background: #f7f7f7;
}

11
app.js

@ -0,0 +1,11 @@
App({
onLaunch(options) {
// 第一次打开
// options.query == {number:1}
console.info('App onLaunch');
},
onShow(options) {
// 从后台被 scheme 重新打开
// options.query == {number:1}
},
});

8
app.json

@ -0,0 +1,8 @@
{
"pages": [
"pages/index/index"
],
"window": {
"defaultTitle": "My App"
}
}

3
mini.project.json

@ -0,0 +1,3 @@
{
"enableAppxNg": true
}

4
pages/index/index.axml

@ -0,0 +1,4 @@
<view>
this is a blank page
</view>

35
pages/index/index.js

@ -0,0 +1,35 @@
Page({
onLoad(query) {
// 页面加载
console.info(`Page onLoad with query: ${JSON.stringify(query)}`);
},
onReady() {
// 页面加载完成
},
onShow() {
// 页面显示
},
onHide() {
// 页面隐藏
},
onUnload() {
// 页面被关闭
},
onTitleClick() {
// 标题被点击
},
onPullDownRefresh() {
// 页面被下拉
},
onReachBottom() {
// 页面被拉到底部
},
onShareAppMessage() {
// 返回自定义分享信息
return {
title: 'My App',
desc: 'My App description',
path: 'pages/index/index',
};
},
});

1
pages/index/index.json

@ -0,0 +1 @@
{}

BIN
snapshot.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Loading…
Cancel
Save