title: How do I set up a ServiceWorker on amazon S3?
body: <p>I am trying to set up the service worker for a SPA I am making.  Its hosted on AWS with S3.</p>
  
  <p>Despite the file being in the correct place I still get the following errors</p>
  
  <p>/service-worker.js:1 The script has an unsupported MIME type ('text/js').
  <a href="https://djwdy6bk7t99o.cloudfront.net/service-worker.js" rel="nofollow noreferrer">https://djwdy6bk7t99o.cloudfront.net/service-worker.js</a> </p>
  
  <p>Failed to load resource: net::ERR_INSECURE_RESPONSE</p>