react-json-view icon indicating copy to clipboard operation
react-json-view copied to clipboard

JsonView is acting really weird

Open siyavash4812 opened this issue 7 years ago • 5 comments

Hello, I just came across your library and its really nice. I have a problem with the library when I try to load it in my app. As shown in the video it doesn't work as expected. Can you please let me know what I should do or what is causing this?? Is it CSS related by any chance?

This is how it shows up on my app! faulty


This is how I want it to show up! working

Thank you

siyavash4812 avatar Aug 20 '18 23:08 siyavash4812

@siyavash4812 You probably put this into some code sandbox. This is what happened to me earlier today. Actually, in the code sandbox, there is a center alignment to all contents by default, which takes effect on the JSON editor as well. All you need to do is adjust the alignment in the CSS.

MarkShulhin avatar Aug 22 '18 14:08 MarkShulhin

Hey @siyavash4812 , did you solve this? I'm having the same problem here.

mahmudulshuvo avatar Sep 29 '18 11:09 mahmudulshuvo

Same Issue

jjwallace avatar Feb 09 '19 04:02 jjwallace

Yes I agree with @MarkShulhin . Just align the text in css. @jjwallace

mahmudulshuvo avatar Feb 10 '19 17:02 mahmudulshuvo

Same, just used text-align: left; css property and it worked. Thanks!

GTFTT avatar Jul 18 '21 20:07 GTFTT