title: npm run build > not creating dist folder in NestJs project
body: <p>I tried to start my project with <code>npm run start:prod</code> command but got </p>
  
  <p><strong><code>Error: Cannot find module {path to my project}\dist\main.js'</code>.</strong></p>
  
  <p>I have tried to rename the path to all my files in the project from src/myController to ../myController .</p>
  
  <p><strong>My package.json (scripts)</strong></p>
  
  <pre><code>"scripts": {
      "build": "tsc -p tsconfig.build.json",
      "format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
      "start": "ts-node -r tsconfig-paths/register src/main.ts",
      "start:dev": "concurrently \"wait-on dist/main.js &amp;&amp; nodemon\" \"tsc -w -p tsconfig.json\" ",
      "start:debug": "nodemon --config nodemon-debug.json",
      "prestart:prod": "rimraf dist &amp;&amp; npm run build",
      "start:prod": "node dist/main.js"
  </code></pre>
  
  <p><strong>My tsconfig.json</strong></p>
  
  <pre><code>{
    "compilerOptions": {
      "module": "commonjs",
      "declaration": true,
      "noImplicitAny": false,
      "removeComments": true,
      "allowSyntheticDefaultImports": true,
      "emitDecoratorMetadata": true,
      "experimentalDecorators": true,
      "target": "es6",
      "sourceMap": true,
      "rootDir": ".",
      "outDir": "../dist",
      "baseUrl": "./src"
    },
    "include": [ "./src/**/*.ts", ],
    "exclude": ["node_modules", "dist", "src/**/*.spec.ts", "src/**/__test__/*"]
  }
  </code></pre>
  
  <p><strong>The actual output:</strong></p>
  
  <blockquote>
    <p>nest-typescript-starter@1.0.0 prestart:prod 
    {path to my project}
    rimraf dist &amp;&amp; npm run build</p>
    
    <p>nest-typescript-starter@1.0.0 build 
    {path to my project}
    tsc -p tsconfig.build.json</p>
    
    <p>nest-typescript-starter@1.0.0 start:prod 
    {path to my project}
    node dist/main.js</p>
  </blockquote>
  
  <p>internal/modules/cjs/loader.js:584
      throw err;
      ^</p>
  
  <blockquote>
    <p>Error: Cannot find module
    {path to my project}\dist\main.js'</p>
  </blockquote>