cytoscape-node-html-label
cytoscape-node-html-label copied to clipboard
Cannot declare and use cytoscape-node-html-label for typescript project.
It would be helpful if u provide or find any similar dependencies of same features or provide @types/cytoscape-node-html-label dependency so that it would be useful that i can use in my typescript project.
Following worked for me to quickly test this in a typescript project
# typings.d.ts
declare module "cytoscape-node-html-label";
# test-cytoscape.ts
import { Core } from "cytoscape";
import nodeHtmlLabel, { CytoscapeNodeHtmlParams, CytoscapeContainerParams } from "cytoscape-node-html-label";
export interface IExtendedCytoscapeCore extends Core {
nodeHtmlLabel: (options: CytoscapeNodeHtmlParams[], params?: CytoscapeContainerParams) => void;
}
const cy = cytoscape(opts) as IExtendedCytoscapeCore;
Will probably become easier when https://github.com/kaluginserg/cytoscape-node-html-label/pull/45 is merged.