iVis-at-Bilkent / cytoscape.js-graphml

A Cytoscape.js extension to import from and export to GraphML format
MIT License
31 stars 8 forks source link

Using in browser #13

Closed mihairaulea closed 5 years ago

mihairaulea commented 5 years ago

Hi, thanks for this, it's very useful for peeps working on the server side of things 👍 How do i use this in a vanilla js setting, aka in a browser?

I am new to cytoscape and don't do much js, so am grateful for your patience.

hasanbalci commented 5 years ago

Here is a sample usage of the extension in the browser and this is the result. However, this extension is not implemented in vanilla js, it requires jQuery as a dependency.

mihairaulea commented 5 years ago

cytoscape.min.js:23 Uncaught TypeError: Cannot read property 'x' of undefined at cytoscape.min.js:23 at ui (cytoscape.min.js:23) at ua.Jr.boundingBox (cytoscape.min.js:23) at Wa.getFitViewport (cytoscape.min.js:23) at Wa.fit (cytoscape.min.js:23) at ua.layoutPositions (cytoscape.min.js:23) at a.Qa.run (cytoscape.min.js:23) at importer.js:70 at Wa.batch (cytoscape.min.js:23) at module.exports (importer.js:35)

hasanbalci commented 5 years ago

Can you try it again? There was a small bug in demo file and I fixed it.