Skip to content

Commit 150ec2e

Browse files
committed
chore: rename variable
1 parent 689b451 commit 150ec2e

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

template/javascript/build.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,15 @@ async function buildComponentLibrary(name) {
100100
const pkgPath = fileURLToPath(
101101
new URL(import.meta.resolve(`${name}/package.json`)),
102102
);
103-
const modulePath = path.dirname(pkgPath);
103+
const libPath = path.dirname(pkgPath);
104104
const { miniprogram } = await fs.readJson(pkgPath, 'utf8');
105105

106106
let source = '';
107107
if (miniprogram) {
108-
source = path.join(modulePath, miniprogram);
108+
source = path.join(libPath, miniprogram);
109109
} else {
110110
try {
111-
const dist = path.join(modulePath, 'miniprogram_dist');
111+
const dist = path.join(libPath, 'miniprogram_dist');
112112
const stats = await fs.stat(dist);
113113
if (stats.isDirectory()) {
114114
source = dist;

template/typescript/build.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,15 @@ async function buildComponentLibrary(name) {
100100
const pkgPath = fileURLToPath(
101101
new URL(import.meta.resolve(`${name}/package.json`)),
102102
);
103-
const modulePath = path.dirname(pkgPath);
103+
const libPath = path.dirname(pkgPath);
104104
const { miniprogram } = await fs.readJson(pkgPath, 'utf8');
105105

106106
let source = '';
107107
if (miniprogram) {
108-
source = path.join(modulePath, miniprogram);
108+
source = path.join(libPath, miniprogram);
109109
} else {
110110
try {
111-
const dist = path.join(modulePath, 'miniprogram_dist');
111+
const dist = path.join(libPath, 'miniprogram_dist');
112112
const stats = await fs.stat(dist);
113113
if (stats.isDirectory()) {
114114
source = dist;

0 commit comments

Comments
 (0)