Hi,
I've started using Awful 1.0 and having trouble returning a JSON string. The inverted commas are being replaced by ". For example, using the code below returns {"a" : 1 }
Should this be normal behavior when returning JSON strings?
Thanks.
David
(use awful)
(enable-sxml #t)
(define my-json "{\"a\" : 1 }")
(define (define-json path body)
(define-page path
(λ ()
(awful-response-headers '((content-type "text/json")))
(body))
no-template: #t))
(define-json (main-page-path)
(λ () `(,my-json)))