title: Getting name property from package.json with NodeJS
body: <p>I would like to know if there is a way in NodeJs to get the name property from my project <code>package.json</code> file:</p>
  
  <pre><code>{
      "name": "bendiciones",
      "version": "1.12.0",
      "description": " bendiciones",
      "main": "main.js",
      "scripts": {
  ...
  }
  </code></pre>
  
  <p>I've tried with</p>
  
  <pre><code>import {name} from './package.json';
  import {name} from './app.json'
  </code></pre>
  
  <p>but I got the errors:</p>
  
  <pre><code>TS2307: Cannot find module './package.json'.
  TS2307: Cannot find module './app.json'.
  </code></pre>
  
  <p>I've tried also with:</p>
  
  <pre><code> console.log ('--2&gt;', process.env.npm_package_name);
  </code></pre>
  
  <p>but I get <code>undefined</code></p>