title: BUILD ERROR - Unexpected token / in JSON at position 0
body: <p>I have created a angular library named ng-common-lib. Created a component in side library which reads contents from a json file.</p>
  
  <p>jsonFile.json</p>
  
  <pre><code>{
      "name" : "Sunil"
  }
  </code></pre>
  
  <p>Below code to read json file in my component.</p>
  
  <pre><code>import * as jsonFile from '../../../assets/jsonFile.json';
  .....
  ngOnInit() {
      console.log(jsonFile); 
  }
  </code></pre>
  
  <p>Added below two lines to <strong>tsconfig.json</strong> to read data from json file.</p>
  
  <pre><code>"resolveJsonModule": true,
  "esModuleInterop": true,
  </code></pre>
  
  <p>Then I have ran <strong>ng build ng-common-lib</strong> command to generate build, but it got failed with below error.</p>
  
  <pre><code>users-iMac:ng-ui-library user$ ng build ui-components
  Building Angular Package
  Building entry point '@ui/components'
  Compiling TypeScript sources through ngc
  Bundling to FESM2015
  
  BUILD ERROR
  Unexpected token / in JSON at position 0
  SyntaxError: Unexpected token / in JSON at position 0
      at JSON.parse (&lt;anonymous&gt;)
      at Object.transform (/Users/vasu/Desktop/Sunil/Practice/ng-ui-lib/node_modules/rollup-plugin-json/dist/rollup-plugin-json.cjs.js:18:20)
      at /Users/vasu/Desktop/Sunil/Practice/ng-ui-lib/node_modules/rollup/dist/rollup.js:20962:25
      at &lt;anonymous&gt;
  </code></pre>
  
  <p>Please help to solve this issue.</p>