@sigma/utils
TypeScript icon, indicating that this package has built-in type declarations

3.0.0 • Public • Published

Sigma.js - Utils

This package contains various utils functions to ease the use of sigma.js, and expose some code snippets that are very useful, but are not important and complex enough to deserve their own package.

fitViewportToNodes and getCameraStateToFitViewportToNodes

These functions allow moving a sigma instance's camera so that it fits to a given group of nodes.

getNodesInViewport

This function allows retrieving the list of nodes that are visible (even partially) in the current viewport.

Please check the related Storybook for more advanced examples.

Readme

Keywords

none

Package Sidebar

Install

npm i @sigma/utils

Weekly Downloads

364

Version

3.0.0

License

MIT

Unpacked Size

58 kB

Total Files

13

Last publish

Collaborators

  • jacomyal