📊 Angular
Q. How do you prevent Angular from sanitizing and trusting HTML content?
  • (A) Use DomSanitizer’s bypassSecurityTrustHtml method
  • (B) Use innerHTML binding directly
  • (C) Use ngNonBindable directive
  • (D) Use Renderer2
💬 Discuss
✅ Correct Answer: (A) Use DomSanitizer’s bypassSecurityTrustHtml method

Explanation: DomSanitizer allows marking HTML as safe to bypass Angular sanitization.

Explanation by: Mr. Dubey
DomSanitizer allows marking HTML as safe to bypass Angular sanitization.

💬 Discussion


📊 Question Analytics

👁️
56
Total Visits
📽️
9 mo ago
Published
🎖️
Mr. Dubey
Publisher
📈
96%
Success Rate