Comments (17)
So I have an instance of leaflet map inside the vue instance & a string (API token for leaflet). I'm pretty sure that is all.
from devtools.
What does the error stack look like?
from devtools.
Here you go...
Uncaught TypeError: Converting circular structure to JSON
Save.stringify @ extensions::SafeBuiltins:82
PortImpl.postMessage @ extensions::messaging:53
target.(anonymous function) @ extensions::SafeBuiltins:19
publicClass.(anonymous function) @ extensions::utils:94
sendMessageToDevtools @ proxy.js:73
from devtools.
Pretty sure you've got an object inside itself somewhere in your data. Should vue-devtools handle this case?
from devtools.
Just came across this issue, in my case I have an object (es6 class) that gets the $vm
in it's constructor, and then the object is set in the vm's $data
array and that causes a circular reference that can't be converted to JSON.
from devtools.
I am having the same issue using Mapbox (built on Leaflet). Makes me wonder if that is no coincidence. This could be an issue with how the Leaflet object is structured.
from devtools.
I personally restructured my code, and didn't have any more issues after that. Basically I have a class that gets $vm
through the constructor, but I don't set that object as a $data
attribute to avoid circular references.
from devtools.
Having the same issue with google maps
from devtools.
I too am having the same problem with google maps
from devtools.
Vue Devtools should definitely handle circular references gracefully.
When Vue Devtools is generating the data/property value tree, it should check to see if an object is the same object as any of its ancestors, and instead of going deeper, show "«circular reference»".
from devtools.
@Glutnix where in the code does that occur? Sounds like something this group could fix for @yyx990803
from devtools.
I don't know, I haven't consulted the source code. I just described how you prevent circular references.
from devtools.
fixed via 2a626a3
from devtools.
Thank you Evan!
from devtools.
I still have this issue in vue 2.0-rc.6 with leaflet
from devtools.
@codeofsumit try circular-json
:
const CircularJSON = require('circular-json');
let json = CircularJSON.stringify(yourObject);
from devtools.
I'm working with Typescript + Vue project, had this error when working with openlayers.
The fix for me was to : Mounted() { } in my .ts file.
Ref: https://forum.vuejs.org/t/reference-an-inner-div-inside-of-template/19903/2
from devtools.
Related Issues (20)
- Vue Devtools' detector-exec.js in combination with Cookiebot prevents DOMContentLoaded event? HOT 1
- Performance tab: Wrong timing shown on group
- Devtools Gets "Stuck", Doesn't Refresh on Browser Refresh HOT 12
- Unable to view event details in timeline
- Some component does not show the props panel. HOT 2
- Component State Not Updating HOT 3
- Cannot view AForm(from ant-design-vue) components details, showed me 'Select A Component' HOT 1
- If the base option is configured for Vite, open in editor will fail
- no funciona HOT 2
- README: Mention and link to devtools-next
- Multiple Vue apps mounted cause empty devtools on Chrome HOT 3
- Quickly open the closest parent component that can be opened in the editor.
- It is suspected that vue-devtools causes chrome memory overflow and then crashes HOT 11
- Vue3 chrome devtool not working when vite-plugin-vue-devtools node module is enabled HOT 2
- [PSA] Devtools Next for Vue 3 + Vite users HOT 1
- Pages: mishandling of navigation routes with regex pattern matching HOT 1
- Hotkeys for Vue DevTools HOT 1
- Add way to inspect the dependency chain of a piece of reactive state
- Vue Detected No Components Shown HOT 1
- Infinite loop bug. When the developer tools are closed, an infinite loop bug may occur. HOT 1
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.