Core: Rendering HTML content as Response adonisjs

Created on 25 Aug 2018  路  3Comments  路  Source: adonisjs/core

How can i bind html i.e
under P tag

This is some text

from database showing exactly in our view. Angularjs provide $sce.trustAsHtml method, Is there any helper method for this ..?

Most helpful comment

You should use the forums / discord for questions.

But...

  1. If you don't want to escape the html data then output it with {{{ ... }}} instead of {{ ... }}
    https://edge.adonisjs.com/docs/syntax-guide#_interpolation
  2. Can never be sure if its just semantics or actual confusion. So.. Adonis is a server side framework as such there is no binding in the views, there is no reactive data, just data passed once to a view.

All 3 comments

You should use the forums / discord for questions.

But...

  1. If you don't want to escape the html data then output it with {{{ ... }}} instead of {{ ... }}
    https://edge.adonisjs.com/docs/syntax-guide#_interpolation
  2. Can never be sure if its just semantics or actual confusion. So.. Adonis is a server side framework as such there is no binding in the views, there is no reactive data, just data passed once to a view.

Thanks @tlgreg

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

seanc picture seanc  路  4Comments

codingphasedotcom picture codingphasedotcom  路  3Comments

ghost picture ghost  路  3Comments

aligoren picture aligoren  路  4Comments

PC-HUB picture PC-HUB  路  4Comments