Subscribe on changes!

The component does not work after it is built.

avatar
Jun 24th 2022

Vue version

3.2.25

Link to minimal reproduction

https://github.com/zhazhazhu/vu3-project

Steps to reproduce

1、pnpm i 2、pnpm run build 3、pnpm run dev

What is expected?

The built components work properly.

What is actually happening?

The v-for or variable is used in the source component, but it does not display properly.

System Info

No response

Any additional comments?

No response

avatar
Jun 24th 2022

The reproduction link is broken...

avatar
Jun 24th 2022

复制链接已断开...

I opened it.

avatar
Jun 24th 2022
 rollupOptions: {
       
        external: ['vue'],
        output: {
       
          globals: {
            vue: 'Vue',
          },
        },
      }
avatar
Jun 24th 2022

First of all, the repo can't running correctly, the The component does not work maybe your vite.config.ts is wrong😉.

avatar
Jun 24th 2022
 rollupOptions: {
       
        external: ['vue'],
        output: {
       
          globals: {
            vue: 'Vue',
          },
        },
      }

success