Generated service worker uses file paths under Windows 10
Created by: jorispz
Can you reproduce the problem with latest npm?
Yes, I upgraded to the npm version 4.6.1 and the proble is reproducible
Description
Under windows, in a brand new project created with create-react-app, the service worker uses the location on disk of the files to be cached in its cache configuration.
Expected behavior
The service worker uses the proper URLs for caching configuration
Environment
react-scripts@1.0.0 node v6.10.1 npm 4.6.1
Windows 10 Any browser (not a browser issue)
Reproducible Demo
Create a brand new app with create-react-app in the environment above, run npm run build
, and check the contents of service-worker.js. It contains file paths, such as
var precacheConfig = [
["C:/dev/temp/pwatest/build/index.html", "df24d8c1abce89d06bc00d2023cdad0c"],
[
"C:/dev/temp/pwatest/build/static/css/main.9a0fe4f1.css",
"3473922d6aed4c20bb69846d6027cacf"
],
[
"C:/dev/temp/pwatest/build/static/js/main.23e5d2a8.js",
"d0f59b7dffbc3ff4835b038c8f3a4fdc"
],
[
"C:/dev/temp/pwatest/build/static/media/logo.5d5d9eef.svg",
"5d5d9eefa31e5e13a6610d9fa7a283bb"
]
]