diff --git a/.github/workflows/alipay.yml b/.github/workflows/alipay.yml index f785988d..65e5ee2d 100644 --- a/.github/workflows/alipay.yml +++ b/.github/workflows/alipay.yml @@ -37,10 +37,13 @@ jobs: }' > .minicirc fi - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 + - name: Install pnpm + run: corepack enable + + - uses: actions/setup-node@v3 with: - node-version: "14.x" + node-version: '18' + cache: 'pnpm' - name: upload diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 21c0f573..26afccb9 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -18,7 +18,9 @@ jobs: registry-url: https://registry.npmjs.org - name: Install Dependencies - run: pnpm + run: | + npm install pnpm -g + pnpm install - name: Run Compiler run: pnpm compiler diff --git a/.github/workflows/oss.yml b/.github/workflows/oss.yml index 56ba2c17..4098118a 100644 --- a/.github/workflows/oss.yml +++ b/.github/workflows/oss.yml @@ -12,11 +12,14 @@ jobs: steps: - name: Checkout Repository uses: actions/checkout@v2 + + - name: Install pnpm + run: corepack enable - - name: 设置 Node.js 18.x 环境 - uses: actions/setup-node@v2 + - uses: actions/setup-node@v3 with: - node-version: '18.x' + node-version: '18' + cache: 'pnpm' - name: Install Dependencies and Build Docs run: | diff --git a/.github/workflows/weixin.yml b/.github/workflows/weixin.yml index 46100a7a..f645e031 100644 --- a/.github/workflows/weixin.yml +++ b/.github/workflows/weixin.yml @@ -41,10 +41,13 @@ jobs: }' > .minicirc fi - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v3 + - name: Install pnpm + run: corepack enable + + - uses: actions/setup-node@v3 with: - node-version: "14.x" + node-version: '18' + cache: 'pnpm' - name: upload diff --git a/docs/.vitepress/theme/components/CustomFooter.vue b/docs/.vitepress/theme/components/CustomFooter.vue index 44e84335..bc019333 100644 --- a/docs/.vitepress/theme/components/CustomFooter.vue +++ b/docs/.vitepress/theme/components/CustomFooter.vue @@ -4,11 +4,11 @@ import { useSidebar } from 'vitepress/dist/client/theme-default/composables/side import { computed } from 'vue'; -const { theme, frontmatter } = useData() +const { theme } = useData() const { hasSidebar } = useSidebar() const copyright = computed(()=>{ - const isNetlify = location.href.includes('netlify') + const isNetlify = typeof window !== 'undefined' ? window.location.href.includes('netlify') : false if (!isNetlify) { return `${theme.value.footer.copyright} | This site is powered by Netlify` }else{ diff --git a/docs/.vitepress/theme/components/frame.vue b/docs/.vitepress/theme/components/frame.vue index 5706143f..a4b8160c 100644 --- a/docs/.vitepress/theme/components/frame.vue +++ b/docs/.vitepress/theme/components/frame.vue @@ -4,8 +4,8 @@