Comments (9)
Can you add a debugger statement there and see what data
contains? This error is usually thrown when the data to be sent contains non-plain objects e.g. functions.
from devtools.
Yes I did this. It contains component props. One of them was a function.
from devtools.
event: "instance-details"
payload: Object
id: 4
name: "Datatable"
state: Array[5]
0: Object
key: "items"
meta: Object
type: "prop"
value: Array[8]
__proto__: Object
1: Object
key: "onSelect"
meta: Object
binding mode: "default"
required: false
type: "Function"
__proto__: Object
...
from devtools.
Can you be more specific about where the function was found?
from devtools.
Did you mean component definition? If yes, it looks like:
<script>
module.exports = {
methods: {
doSomething () {/* */}
},
components: {
datatable: {
props: {
items: /* */,
onSelect {
type: Function,
default () {return function () {}}
}
}
}
}
}
</script>
<template>
<datatable :on-select="doSomething"></datatable>
</template>
When I click to <datatable>
in vue-devtools I am getting error described above.
It may be because in shells/chrome/src/backend.js line 26 data.payload.state[1].type
is a Function
for this component.
If something is wrong with my answer, sorry :) Let me know if I can provide additional information for this.
from devtools.
It looks like I did something the other way this time. There is value
property in data.payload.state[1]
what contains function... So it looks like:
event: "instance-details"
...
payload: Object
state: [5]
...
1: Object
key: "onSelect"
meta: Object
type: "prop"
value: function (a)
__proto__: Object
from devtools.
Adding filtration for value
makes it work well:
if (data.payload.state) {
data.payload.state = data.payload.state.filter(function (el) {
return !(el.value instanceof Function)
})
}
It seems we should somehow replace these functions with something else...
from devtools.
Ok, should be fixed in 1.0.1 with proper sanitization before sending the data.
from devtools.
Thanks, Evan!
from devtools.
Related Issues (20)
- Standalone vue-devtools depends on vulnerable version of Electron HOT 1
- No info in selected component HOT 4
- It is suggested to add a multi-language switch function.
- Bump manifest from v2 to v3 HOT 2
- Can the responsive variables in the setup also be displayed on the debugging interface for users of tsx/jsx notation?
- In the standalone version of Vue devtools 7, the component picker button is nowhere to be found HOT 1
- Pinia doesn't show up in devtools (Nuxt 3 app) HOT 2
- Suddenly Pinia doesn't show up anymore HOT 1
- Vue devtools crashes chrome HOT 3
- Jumping to top of Apps list HOT 1
- 使用Element-plus的upload时,开发者工具看不到绑定在upload的值上的response
- devtool does not appear HOT 71
- Loads of Vue warns with 6.6.0 HOT 1
- Cannot update Pinia values
- Add UI scale
- component selection tool not working HOT 11
- Freezing Microsoft Edge
- The extension conflicts with walutomat.pl (the site is broken when the extension is enabled) HOT 1
- state, render, currentRoute errors in console HOT 3
- Component graph doesn't show custom renderer components
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from devtools.