The API currently only supports one level of nested configurators
This article assumes you read and undersatnd how to Embed the Threekit Player & Configurator into a webpage
Retrieving Nested Config
To retrieve the nested configurator details for a selected product, utilize the
getConfigurator() function from the Player API while passing in the name of the top level Attribute which contains the nested product. This function returns the configurator api for the currently selected product. In order to maintain the top level configurator API, it’s best to create a separate variable for the nested configuration.
nestedConfigurator = await window.player.getConfigurator('Nested Configurator 1');
getDisplayAttributes() function may be used to retrieve all the attribute information which needed to create the form for the nested configurator.
Paste the following code snippet into the console and familiarize yourself with the object structure:
curDispAttributes = nestedConfigurator.getDisplayAttributes();
The setConfiguration() function is used to set the configurator when the user changes values on the form in the custom UI.
Paste the following code into the console and note the color of the asset updates to Orange. Try setting other attributes.