From 3836427aecc4897bbe101d36c2f80d466cd428cd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E5=91=98=E5=B0=8F=E5=A2=A8?=
<2291200076@qq.com>
Date: Sat, 26 Nov 2022 00:48:09 +0800
Subject: [PATCH] =?UTF-8?q?=E5=B0=86=E8=B0=83=E8=AF=95=E5=86=85=E5=AE=B9?=
=?UTF-8?q?=E6=8A=BD=E7=A6=BB=E5=87=BAComponent?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.gitignore | 1 +
README.md | 4 ++
backend-mock/index.js | 6 +--
miniprogram/project.alipay.json | 5 +++
miniprogram/src/components/DebugComp.vue | 49 ++++++++++++++++++++++++
miniprogram/src/pages/index/index.vue | 34 +++-------------
miniprogram/src/pages/index/login.vue | 5 +--
7 files changed, 69 insertions(+), 35 deletions(-)
create mode 100644 miniprogram/project.alipay.json
create mode 100644 miniprogram/src/components/DebugComp.vue
diff --git a/.gitignore b/.gitignore
index 543e255..bce00e6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -15,3 +15,4 @@
.vscode
ignore/*
+start-nacos.bat
diff --git a/README.md b/README.md
index dd34808..4be53a4 100644
--- a/README.md
+++ b/README.md
@@ -337,6 +337,10 @@ npm run build:alipay
打开**小程序开发者工具**,小程序目录选择 `miniprogram/dist` 目录
+**重点:点开右上角【详情】,勾选【小程序配置】下的 `启用小程序基础库2.0构建` 和 `编译node_modules模块(ES6转ES5)`。**
+
+需要注意的是,支付宝小程序打包很慢,需要等比较长的时间。
+
接下来按照正常的小程序发布流程进行发布即可。发布前记得测试小程序各功能是否正常。
diff --git a/backend-mock/index.js b/backend-mock/index.js
index bdc36be..5124e57 100644
--- a/backend-mock/index.js
+++ b/backend-mock/index.js
@@ -56,9 +56,9 @@ server.on("request", (req, res) => {
res.end();
})
-// 4. 监听端口,为了避免端口冲突,这里给一个本机端口3000
-server.listen(8080, () => {
- let baseUrl = 'http://localhost:8080';
+// 4. 监听端口,为了避免端口冲突,这里给一个本机端口
+server.listen(80, () => {
+ let baseUrl = 'http://localhost:80';
console.log(`服务启动成功: ${baseUrl}/`);
console.log();
console.log(`${baseUrl}/user/login`);
diff --git a/miniprogram/project.alipay.json b/miniprogram/project.alipay.json
new file mode 100644
index 0000000..50d5152
--- /dev/null
+++ b/miniprogram/project.alipay.json
@@ -0,0 +1,5 @@
+{
+ "enableAppxNg": true,
+ "enableNodeModuleBabelTransform": false,
+ "miniprogramRoot": "./"
+}
diff --git a/miniprogram/src/components/DebugComp.vue b/miniprogram/src/components/DebugComp.vue
new file mode 100644
index 0000000..3caf6a7
--- /dev/null
+++ b/miniprogram/src/components/DebugComp.vue
@@ -0,0 +1,49 @@
+
+
+
+
+
+
+
+
diff --git a/miniprogram/src/pages/index/index.vue b/miniprogram/src/pages/index/index.vue
index 1cb460e..6d746ab 100644
--- a/miniprogram/src/pages/index/index.vue
+++ b/miniprogram/src/pages/index/index.vue
@@ -96,16 +96,14 @@
-
-
- {{ debugText }}
-
+