Commit c265b3a6 authored by 劳琪峰's avatar 劳琪峰

chore: 页面url生成器

parent c0881899
const hosts = [ const hosts = [
{value: 'https://guide-api.feihe.com', alias: '生产环境域名'}, {value: 'https://guide-api.feihe.com', alias: '生产环境'},
{value: 'https://guide-api-test.feihe.com', alias: 'test环境域名'}, {value: 'https://guide-api-test.feihe.com', alias: 'test环境'},
{value: 'https://guide-api-uat.feihe.com', alias: 'uat环境域名'}, {value: 'https://guide-api-uat.feihe.com', alias: 'uat环境'},
] ]
const pages = [ const pages = [
{value: '/mini/#/page/momHome/index', alias: '妈妈爱活动入口'}, {value: '/mini/#/page/momHome/index', alias: '妈妈爱活动'},
{value: '/mini/#/page/home/index', alias: '路演活动入口'}, {value: '/mini/#/page/home/index', alias: '路演活动'},
] ]
const mpPage = '/pages/webview/webview' const mpPage = '/pages/webview/webview'
for (const host of hosts) { for (const page of pages) {
for (const page of pages) { for (const host of hosts) {
const url = `${mpPage}?url=${encodeURIComponent(host.value + page.value)}` const url = `${mpPage}?url=${encodeURIComponent(host.value + page.value)}`
console.log(`${host.alias}-${page.alias}: ${url}`) console.log(`${page.alias}-${host.alias}: ${url}`)
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment