The script has an unsupported MIME type ('text/html').
A quick fix would be to copy the service-worker.js file to the public folder
so that when you hit http://localhost:3000/service-worker.js you see the file
in the browser.
The script has an unsupported MIME type ('text/html').
A quick fix would be to copy the service-worker.js file to the public folder
so that when you hit http://localhost:3000/service-worker.js you see the file
in the browser.
the script has an unsupported mime type (
app.get("/service-worker.js", (req, res) => {
res.sendFile(path.resolve(__dirname, "public", "service-worker.js"));
});
app.get("*", function response(req, res) {
res.sendFile(path.join(__dirname, "public", "index.html"));
});
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us