Unexpected performance warning
Version
3.0.0
Reproduction link
https://drive.google.com/file/d/1hP3YMk3iXbj9l-m5NMqy3KELtKA0t1fN/view?usp=sharing
Steps to reproduce
Just run the project
What is expected?
No warning
What is actually happening?
Warning
You should mark it as Raw when passing to data:
import { markRaw } from '@vue/reactivity'
import Text from './components/Text'
export default {
name: 'App',
data() {
return {
Component: markRaw(Text)
}
}
}
or Use the name if you register it:
import { markRaw } from '@vue/reactivity'
import Text from './components/Text'
export default {
name: 'App',
// registered
components: { Text },
data() {
return {
Component: 'Text'
}
}
}
then
<component :is="Component" />
Please, next time consider using the forum, the Discord server or StackOverflow for questions first. But feel free to come back and open an issue if it turns out to be a bug 🙂