Subscribe on changes!

打包后ref获取节点失败

avatar
Nov 10th 2022

Vue version

3.2.8

Link to minimal reproduction

https://nkapp.huayuan001.com/resources/dist/index.html#/

Steps to reproduce

import { ref, onMounted } from 'vue'

onMounted(() => { console.log(page.value); })

What is expected?

What is actually happening?

undefined

System Info

System:
    OS: Windows 10 10.0.22621
    CPU: (16) x64 AMD Ryzen 7 5800H with Radeon Graphics
    Memory: 6.00 GB / 15.37 GB
  Binaries:
    Node: 14.21.1 - D:\nodejs\node.EXE
    npm: 6.14.17 - D:\nodejs\npm.CMD
  Browsers:
    Edge: Spartan (44.22621.819.0), Chromium (107.0.1418.35)
    Internet Explorer: 11.0.22621.1
  npmPackages:
    vue: ^3.2.8 => 3.2.8

Any additional comments?

在测试环境是正常的,但是当我打包后就变成了undefined

avatar
Nov 10th 2022

Not a valid reproduction. Assuming duplicate of https://github.com/vuejs/core/issues/6677