diff --git a/packages/vant/docs/site/use-translate.ts b/packages/vant/docs/site/use-translate.ts index 7d29e43d3..38c33dda2 100644 --- a/packages/vant/docs/site/use-translate.ts +++ b/packages/vant/docs/site/use-translate.ts @@ -104,3 +104,7 @@ export function useTranslate(i18n: Record) { return createTranslate(demoName); } + +/** Generate the CDN URL of assets. */ +export const cdnURL = (path: string) => + `https://cdn.jsdelivr.net/npm/@vant/assets/${path}`; diff --git a/packages/vant/src/button/demo/index.vue b/packages/vant/src/button/demo/index.vue index 1b328962f..9460e3105 100644 --- a/packages/vant/src/button/demo/index.vue +++ b/packages/vant/src/button/demo/index.vue @@ -1,6 +1,6 @@