json-schema-viewer icon indicating copy to clipboard operation
json-schema-viewer copied to clipboard

Need help in getting tree state(expanded or collapsed) of JSON schema

Open sreevidyaJ opened this issue 2 years ago • 1 comments

Hi Team,

I'm new to @stoplight/json-schema-viewer. I'm using @stoplight/json-schema-viewer: 3.1.1 version

<JsonSchemaViewer name="Todos Model" schema={schema} expanded={true} hideTopBar={false} emptyText="No schema defined" defaultExpandedDepth={0} /> I'm implementing expand all and collapse all feature. I want to get tree state of json schema(if any node is expanded or not), that I could use it for further coding. could you please help me, how can i get the tree state.

Thanks, Sreevidya

sreevidyaJ avatar Jul 28 '21 11:07 sreevidyaJ

@sreevidyaJ Did you ever found a solution?

weyert avatar Sep 01 '23 12:09 weyert