Build a JSON Viewer that renders any given valid JSON structure as a tree similar to the provided designs.
- Any
object
orarray
should be collapsible. ( i.e, Any property that can have nested properties should be collapsible )- The “root” object should be expanded by default.
- All child properties should be collapsed by default.
- When the “create column” button is clicked, it should simply copy the “json path” of the property into the clipboard.
- Animations and transitions would be a bonus.
- The nested property should remember its “expanded” or “collapsed” state even if the parent toggles between expanded or collapsed.
React, Next 14, TypeScript, React context, Mantine, TailiwndCSS
npm i
npm run dev