title: CSP ionic resource load blocked
body: <p>I am trying to load a resource in json format from a service on another pc, but I cannot get through and get a CSP error and the resource doesnt load. When I tried to connect to an online source (reddit), it worked just fine and returned me a json item.</p>
  
  <p>my index.html's head</p>
  
  <pre><code>&lt;head&gt;
  &lt;meta charset="UTF-8"&gt;
  &lt;title&gt;Ionic App&lt;/title&gt;
  &lt;meta http-equiv="Content-Security-Policy"content="default-src 'self' gap://ready file://*http://192.168.201.55:8100data: gap:;style-src 'self' 'unsafe-inline';media-src *;script-src 'self' 'unsafe-inline' 'unsafe-eval'"&gt;
  &lt;meta http-equiv="Content-Security-Policy"content="default-src 'self' gap://ready file://*http://pc_lesmes:8088data: gap:;style-src 'self' 'unsafe-inline';media-src *;script-src 'self' 'unsafe-inline' 'unsafe-eval'"&gt;
  &lt;meta name="viewport" content="viewport-fit=cover, width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"&gt;
  &lt;meta name="format-detection" content="telephone=no"&gt;
  &lt;meta name="msapplication-tap-highlight" content="no"&gt;
  &lt;link rel="icon" type="image/x-icon" href="assets/icon/favicon.ico"&gt;
  &lt;link rel="manifest" href="manifest.json"&gt;
  &lt;meta name="theme-color" content="#4e8ef7"&gt;
  &lt;!-- add to homescreen for ios --&gt;
  &lt;meta name="apple-mobile-web-app-capable" content="yes"&gt;
  &lt;meta name="apple-mobile-web-app-status-bar-style" content="black"&gt;
  &lt;!-- cordova.js required for cordova apps (remove if not needed) --&gt;
  &lt;script src="cordova.js"&gt;&lt;/script&gt;
  &lt;!-- un-comment this code to enable service worker&lt;script&gt;if ('serviceWorker' in navigator) {navigator.serviceWorker.register('service-worker.js').then(() =&gt; console.log('service worker installed')).catch(err =&gt; console.error('Error', err));}&lt;/script&gt;--&gt;
  &lt;link href="build/main.css" rel="stylesheet"&gt;
  &lt;/head&gt;
  </code></pre>
  
  <p>I am trying to connect to this pc_lesmes's service but my firefox's console shows an error, pointing out "unvalid host cannot be interpreted" and "options for this page have prevented the load of a resource from pc_lesmes" Please note these are not the literall error codes but a translation.</p>
  
  <p>What should I do in order to fix it? Also, ¿Do you know any reliable source for learning more about CSP? Thank you very much for your answers and time.</p>
  
  <p><strong>EDIT</strong>: If you downvote me, please let me know what am I doing wrong since I have not found any related threads and im trying to follow the guidelines.</p>