skip to Main Content

I have a very basic project set up with 3 json files for Lottie animations, but when I click on one of them in my Project Navigator, Xcode will freeze and eventually become unresponsive. The json file is not big in size either (160 KB). I wonder what’s the cause behind this freezing. Is it a bug in Xcode right now or are you not meant to see your json files other than in "quick view" mode? I’m running Xcode 12.5.

2

Answers


  1. This could happen with "minified" JSON (i.e. on a single line, as opposed to "pretty printed" with line returns and tabs/spaces): the longer the JSON, the longer the single line and some editors might have a hard time rendering it.

    You could "pretty print" your JSON (outside of Xcode) to make it more digestible to the editor but be aware that this might result in significantly bigger (10x) JSON files.

    Login or Signup to reply.
  2. I have the same problem. i tried this:
    My json file consisting of 612 different objects blocks Xcode. So I realized that the problem was that the objects were greater than 599. If I delete 13 objects, everything works fine.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search