26a4eb827c
Drops user `<script>` tags and shows a warning in AMP mode. Right now they are only dropped in production mode and left in dev mode so the validator shows its warning since it looks like conflicting props log messages are being cleared causing them to not show. Closes: #6688
13 lines
305 B
JavaScript
13 lines
305 B
JavaScript
import Head from 'next/head'
|
|
|
|
export default () => (
|
|
<div>
|
|
<Head>
|
|
<script src='/im-not-allowed.js' type='text/javascript' />
|
|
<script dangerouslySetInnerHTML={{
|
|
__html: `console.log("I'm not either :p")`
|
|
}} />
|
|
</Head>
|
|
<p>We only allow AMP scripts now</p>
|
|
</div>
|
|
)
|