• potoo22@programming.dev
    link
    fedilink
    arrow-up
    5
    arrow-down
    1
    ·
    1 year ago

    It’s only invalid if it generated errors.

    But yeah, I typically play it safe and follow the standards. I do wish JSON5 would catch on though.

    • TehPers@beehaw.org
      link
      fedilink
      English
      arrow-up
      11
      ·
      1 year ago

      It’s only invalid if it generated errors.

      I understand this line of thinking, but unless they specify what “flavor” of JSON they accept, I think it’s safe to assume they only accept what’s in spec. What I find weird is that they immediately contradict the spec with their example by writing JavaScript. Should the content-type then be application/javascript? They can easily document the parameters outside the request body instead of adding comments.

      Also, yes, I know I’m being pedantic, but if I’m applying for a job, it’s a two way application. They need to give me reason to trust that they’re worth working for. Making up rules along the way when referencing a commonly known spec doesn’t give me much confidence.