Skip to content
Permalink
Browse files

Add 'nonce' demo

  • Loading branch information...
marcomontalbano committed Nov 4, 2019
1 parent e021d5c commit 154ac259a7be12dd06982e9d9dafbfe1250ae358
Showing with 550 additions and 0 deletions.
  1. +1 −0 Procfile
  2. +17 −0 index.hbs
  3. +471 −0 package-lock.json
  4. +28 −0 package.json
  5. +33 −0 server.js
@@ -0,0 +1 @@
web: npm start
@@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>

<link rel="stylesheet" href="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@9.16.2/build/styles/atom-one-dark.min.css">

<script nonce="{{ nonce }}">alert('Hi from "nonce" script!')</script>
<script>alert('Loaded from a "non-nonce" script!')</script>

</head>
<body>

<p>Hello World!</p>
<pre><code class="hljs javascript">{{{ jscode }}}</code></pre>

</body>
</html>

0 comments on commit 154ac25

Please sign in to comment.
You can’t perform that action at this time.