Closed marcklingen closed 2 months ago
OK, I will, my heavy account 😂.
react18-json-view@0.2.8-canary.2 available, Sir. @marcklingen
Thank you! Just tried it, does not work for me (no content is shown anymore). I upgraded from react18-json-view@0.2.8-canary.1 to react18-json-view@0.2.8-canary.2.
Please try @0.2.8-canary.3 again. @marcklingen
Awesome! works on our end to edit strings that were already strings before.
Only question that's kind of left is how to switch from object to array to scalar when using the component to edit the object.
https://github.com/YYsuni/react18-json-view/assets/2834609/13545d31-f7af-452d-b1b5-bb001c90e42c
For creating a object, you can view https://github.com/YYsuni/react18-json-view?tab=readme-ov-file#editable. And others, I will take care of that.
On @0.2.8-canary.4, you could delete the root node and reset it, @marcklingen
@marcklingen Hi?
Hi @YYsuni, I tried it again a couple of times but then got a lot of feedback by our users who edit a lot of JSON within our application. We switched to codemirror for editing and use react18-json-viewer for viewing of JSON across the UI. react18-json-viewer
is awesome when editing single values but not when writing large JSON objects. Having multi-cursors and other editor features is preferred for that use case.
Currently
editable
works if the root node is of type object. JSON roots can also be arrays or scalars, these do not seem to be editable in react18-json-view as of now (if I did not do a mistake).Do you think adding this functionality is reasonable? Otherwise, we would build alternative UI in our project to toggle the JSON editor or default to a regular input field to edit scalars (strings).
Example (https://github.com/langfuse/langfuse)