-
Notifications
You must be signed in to change notification settings - Fork 425
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
Graph Inside Div #6
Comments
When you create a renderer instance set the 'container' property to required DOM element, where you want to place a graph. E.g. var renderer = Viva.Graph.View.renderer(graph,
{
container : document.getElementById('graphDiv')
// other settings
}); |
@anvaka This is probably going to be a popular question. You may want to therefore address this question right at the beginning of your first example. Specifically in the readme.md would be best imo. That's where I was missing it. Thanks! looking forward to trying this out. Looks awesome in the demos! |
@Clay-Ferguson thanks! fixed |
I tried to run it, and it renders a canvas object that's 1px by 1px. Not sure what i'm doing wrong. I'm sure I have the JS file loading correctly but not working yet. |
check the CSS for the div - does it have width/height? |
I tried again, but still can't get it. Here's the code: I didn't (nor will I) run any command line code. ALL i'm doing is including
/////////////// // var layout = Viva.Graph.Layout.forceDirected(graph, { var graphics = Viva.Graph.View.webglGraphics(); Best regards, On Wed, Mar 30, 2016 at 11:13 PM, Andrei Kashcha notifications@github.com
|
I am trying to render the Graph inside a div. Not able to figure it out.
How to put the graph in the div?
The text was updated successfully, but these errors were encountered: