Noscript HTML support
See original GitHub issueCurrently it’s impossible to set HTML inside the noscript
tag, as textContent
is used for setting children
. But for setting up GTM, it’d be great to also support their noscript setup:
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-XXXXXXX" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
Which atm gets escaped:
<noscript>
<iframe
src="https://www.googletagmanager.com/ns.html?id=GTM-XXXXXXX"
height="0"
width="0"
style="display: none; visibility: hidden"
></iframe>
</noscript>
Another use-case could be someone wanting to render an image/gif in a noscript tag, which would also be impossible atm.
A workaround for now is using a dynamic component (credit to https://github.com/vuejs/vue/issues/8996#issuecomment-557926912):
<component is="noscript">
<iframe
:src="`https://www.googletagmanager.com/ns.html?id=${GOOGLE_TM_ID}`"
height="0"
width="0"
style="display: none; visibility: hidden"
></iframe>
</component>
Issue Analytics
- State:
- Created a year ago
- Comments:5
Top Results From Across the Web
The Noscript element - HTML: HyperText Markup Language
The <noscript> HTML element defines a section of HTML to be inserted if a script type on the page is unsupported or if...
Read more >"noscript" | Can I use... Support tables for HTML5, CSS3, etc
"Can I use" provides up-to-date browser support tables for support of front-end web technologies on desktop and mobile web ... HTML element: noscript....
Read more >HTML <noscript> Tag - W3docs
The <noscript> tag has an alternative content displayed in the browsers not supporting scripts, or the browsers, where the user disables the script...
Read more >HTML <noscript> Tag - GeeksforGeeks
The <noscript> tag in HTML is used to display the text for those browsers which does not support script tag or the browsers...
Read more >4.3.2 The noscript element — HTML5: Edition for Web Authors
... head element of an HTML document, if there are no ancestor noscript elements. ... that don't support scripting, by affecting how the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@harlan-zw I checked the source and you’re right. Thanks!
Thank you sir!