title: API token added to GitHub Secrets in my repo, deploying GitHub Pages, how do I access this Secret in Javascript? (Simple Node.js project)
body: <p><a href="https://i.stack.imgur.com/Ml7iC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Ml7iC.png" alt="enter image description here" /></a></p>
  <p>This is added to the GitHub pages branch.</p>
  <p>My <code>package.json</code> at the moment looks like this:</p>
  <pre><code>{
    &quot;name&quot;: &quot;project&quot;,
    &quot;version&quot;: &quot;1.0.0&quot;,
    &quot;description&quot;: &quot;project&quot;,
    &quot;main&quot;: &quot;app.js&quot;,
    &quot;dependencies&quot;: {
      &quot;dotenv&quot;: &quot;^8.2.0&quot;,
      &quot;gh-pages&quot;: &quot;^3.1.0&quot;
    },
    &quot;devDependencies&quot;: {},
    &quot;scripts&quot;: {
      &quot;deploy&quot;: &quot;gh-pages -d .&quot;
    },
    &quot;author&quot;: &quot;&quot;,
    &quot;license&quot;: &quot;ISC&quot;,
    &quot;homepage&quot;: &quot;https://USERNAME.github.io/gh-pages-repo&quot;
  }
  </code></pre>
  <p>Up until now, I've stored my Token in a <code>token.js</code> file (which was in .gitignore), imported that into my HTML through a <code>&lt;src&gt;</code>.</p>
  <p>When I've deployed the app with <code>npm run deploy</code>, I don't know exactly how to access this token value. What do I have to change in <code>package.json</code>, and in my Javascript?</p>