Invoke fit/center with an effective area without changing the canvas size. (demo)
- Cytoscape.js ^3.2.0
Download the library:
- via npm:
npm install cytoscape-effective-area,
- via unpkg:
Import the library as appropriate for your project:
let cytoscape = ;let effectiveArea = ;cytoscape; // register extension
Plain HTML/JS has the extension registered for you automatically, because no
require() is needed.
const ea = cy;// Change effective area getter functionea// Disableea// Re-enableea
npm run build: Build
npm run lint: Run eslint on the source
This project is set up to automatically be published to npm and bower. To publish:
- Build the extension :
npm run build
- Commit the build :
git commit -am "Build for release"
- Bump the version number and tag:
npm version major|minor|patch
- Push to origin:
git push && git push --tags
- Publish to npm:
npm publish .