10

I'm implementing a web page with multiple Vue instances.

I have a simple question : is it possible to name and display them under their name with vue-devtools?

Actually my console displays instances like this and it is hard to distinguish them :

vue-devtools

Sebastien D
  • 4,369
  • 4
  • 18
  • 46

2 Answers2

19

By "multiple instances of Vue", if you mean you have multiple new Vue({}) instances, then you can give each its own name as:

new Vue({
  name: 'Samayo'
})

And now the <Root> in your devtools will be replaced with <Samayo>

samayo
  • 16,163
  • 12
  • 91
  • 106
0

For Vue.js 3

createApp({
  name: 'someName',
  // ...
})
Quentin Veron
  • 3,079
  • 1
  • 14
  • 32