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

Set scale #58

Open
JimmyMow opened this issue Dec 4, 2017 · 1 comment
Open

Set scale #58

JimmyMow opened this issue Dec 4, 2017 · 1 comment

Comments

@JimmyMow
Copy link

JimmyMow commented Dec 4, 2017

Is there a way I can set the default scale or a callback to set the scale of InteractiveForceGraph?

@JimmyMow
Copy link
Author

JimmyMow commented Dec 4, 2017

What's happening is I am setting the charge at -500 and when the graph loads it's way too zoomed in

<InteractiveForceGraph
            simulationOptions={
              {
                height: 800,
                width: 800,
                strength: { 
                  charge: -500
                }
              }
            }
            labelAttr='label'
            opacityFactor={1}
            highlightDependencies
            zoomOptions={{ minScale: 0.1, maxScale: 5 }}
            zoom
          >

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

1 participant