JSON-based Javascript serializer.