I am developing a website with a shapeDiver model embedded.
I would like to access grasshopper parameters and update them through the website interface.
The issue is there is an Uncaught reference error when I move the stair width slider that is shown at the first picture which points to the HTML file line 71 where I set two input ranges and control them in js file.
We have updated the code example and it has 2 sliders now. Please have a look and if you still struggle share a CodePen or a minimal example so we can help you to debug.
I am interested in seeing if a similar example has been updated to work in the Shapediver V3 viewer. I have been looking for examples of this type of HTML integration, but the examples in the V3 viewer don’t fit my needs as well as this example appears to.
I have looked at the parameter update example, but the parameter values are hard-coded into the sample code. I am not understanding how to set that to be a variable and how to trigger a change in the viewer when an HTML input updates the variable, much like the simple HTML-based slider in the example in this forum thread. I think just the parameter update example that you linked, but with a text box or slider defined in the index.html file that controls the viewer is all I need to get where I want to go.
My typescript/javascript experience is limited, so I’m sure there is something really basic that I am missing, but this one has been stumping me. So far all of the examples that I have found in V3 either don’t have an HTML interface or are auto-generating all of the HTML elements, which is a lot more than what I need.