Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uncaught TypeError: ani.play is not a function #106

Open
rmant opened this issue Dec 29, 2020 · 3 comments
Open

Uncaught TypeError: ani.play is not a function #106

rmant opened this issue Dec 29, 2020 · 3 comments
Assignees

Comments

@rmant
Copy link

rmant commented Dec 29, 2020

Hi,

When I try to use the cose-bilkent layout, I get the following error:
Uncaught TypeError: ani.play is not a function at cytoscape.cjs.js:11449 at Array.forEach (<anonymous>) at Collection.layoutPositions (cytoscape.cjs.js:11448) at Layout._CoSELayout.run (cytoscape-cose-bilkent.js:349) at new AppComponent (app.js:36) at $ (preact.module.js:1) at m (preact.module.js:1) at $ (preact.module.js:1) at O (preact.module.js:1) at Module../src/client/index.js (index.js:18)

I'm using:

  • Cytoscape 3.17.1
  • cose-base 1.0.3
  • cytoscape-cose-bilkent 4.1.0

And I'm using cose-bilkent the following way:
const layout = cy.layout({ name: 'cose-bilkent', }); layout.run();

@hasanbalci
Copy link
Contributor

@rmant I cannot reproduce it in the demo. Can you provide a JSFiddle or JSBin demo to reproduce this issue? Thanks.

@rmant
Copy link
Author

rmant commented Jan 4, 2021

I can't share my code to reproduce this issue since I'm working with NDA data, but you should be able to reproduce it using the wine and cheese demo, and changing the layout to cose-bilkent or FCoSE

@jamesscottbrown
Copy link

I also encountered this error when trying to compute a layout in nodejs, presumably because animation requires DOM manipulation that is only possible in the browser.

My solution was to disable animations (cy.layout({ name: 'cose-bilkent', animate: false })). I don't know if this is applicable to your situation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants