title: Django rest-framework creating a view without model
body: <p>I am pretty new to Django rest-framework and trying to render a simple JSON view not based on the model. I could not figure out how to do this since all of the examples involves rendering JSON from the Model classes. Below is the simple example what I was trying to do.</p>
  
  <pre><code>class CommentSerializer(serializers.Serializer):
      email = serializers.EmailField()
      content = serializers.CharField(max_length=200)
      created = serializers.DateTimeField()
  
  class Comment(object):
      def __init__(self, email, content, created=None):
          self.email = email
          self.content = content
          self.created = created or datetime.now()
  
  def comment_view(request):
      comment = Comment(email='leila@example.com', content='foo bar')
      serializer = CommentSerializer(comment)
      json = JSONRenderer().render(serializer.data)
      return json
  </code></pre>