Prevent angular from compiling HTML inside in PRE tag

630 views
Skip to first unread message

Naveen Kohli

unread,
Jun 10, 2014, 10:59:28 AM6/10/14
to ang...@googlegroups.com
I am trying to post some angular code as part of blog post. I have put this code in <PRE> tag. And all angle brackets are escaped as well. For some reason angularJS ends up compiling that HTML section and final output on page for that PRE section is "undefined". What will be the best way to deal with it.

Thanks

Kamal

unread,
Jun 10, 2014, 11:35:48 AM6/10/14
to ang...@googlegroups.com
Hi Naveen,

Use the ngNonBindable directive for the pre tag, have a look at the docs at https://docs.angularjs.org/api/ng/directive/ngNonBindable
Reply all
Reply to author
Forward
0 new messages