title: How to load JSON in Vue CLI without CORS error
body: <p>I have a Vue.js project wrapped in an Electron app. From one of my components (<code>src/components/MoviesTable.vue</code>), I'm making an axios call to a local JSON file (<code>public/data/multimedia.json</code>), like this:</p>
  
  <pre><code>axios.get('./data/multimedia.json').then(res =&gt; {
    this.movies = res.data.movies;
  })
  </code></pre>
  
  <p>When I run <code>npm run serve</code> to serve the Vue app, I experience no issues. However, when I build the Electron app, I receive the error:</p>
  
  <blockquote>
    <p>Access to XMLHttpRequest at '.../multimedia-index-app/dist/data/multimedia.json' from origin 'null' has been blocked by CORS policy: Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, https.</p>
  </blockquote>
  
  <p>I've tried using proxies to no avail. I know that similar questions about CORS have been asked on SO, which offer different solutions, but I'm a noob, and I need clearer instructions than the ones that I've come across.</p>
  
  <p>Please let me know if you require more information. Any help in resolving this problem would be greatly appreciated.</p>
  
  <p>Thanks in advance.</p>