Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add escape json #204

Merged
merged 7 commits into from
May 8, 2017
Merged

Add escape json #204

merged 7 commits into from
May 8, 2017

Commits on Apr 4, 2017

  1. Add escapeJson

    Unicode escapes <, >, & as \u003c, \u003e, \u0026 "to keep some browsers
    from misinterpreting JSON output as HTML."
    
    https://golang.org/src/encoding/json/encode.go?s=6456:6499#L48
    
    Also, unicode escapes line and paragraph separators as \u2028, \u2029 "so
    that the JSON will be safe to embed inside HTML <script> tags."
    
    https://golang.org/src/encoding/json/encode.go?s=6456:6499#L184
    http://timelessrepo.com/json-isnt-a-javascript-subset
    Greg Guthe committed Apr 4, 2017
    Configuration menu
    Copy the full SHA
    f28a438 View commit details
    Browse the repository at this point in the history
  2. only escape JSON we care about

    Greg Guthe committed Apr 4, 2017
    Configuration menu
    Copy the full SHA
    c5c19d7 View commit details
    Browse the repository at this point in the history

Commits on Apr 6, 2017

  1. trigger rebuild for travis

    nvm install node fails
    
    refs: nvm-sh/nvm#1349
    Greg Guthe committed Apr 6, 2017
    Configuration menu
    Copy the full SHA
    a758d13 View commit details
    Browse the repository at this point in the history

Commits on Apr 10, 2017

  1. Configuration menu
    Copy the full SHA
    cf70d6d View commit details
    Browse the repository at this point in the history
  2. remove unused namedJson internal

    Greg Guthe committed Apr 10, 2017
    Configuration menu
    Copy the full SHA
    d1231c9 View commit details
    Browse the repository at this point in the history

Commits on Apr 11, 2017

  1. document escapeJSON function

    Greg Guthe committed Apr 11, 2017
    Configuration menu
    Copy the full SHA
    9bff98b View commit details
    Browse the repository at this point in the history

Commits on Apr 12, 2017

  1. escapeJson matching on charcodes

    1-10% faster on the twitter.json
    Greg Guthe committed Apr 12, 2017
    Configuration menu
    Copy the full SHA
    be57205 View commit details
    Browse the repository at this point in the history