Skip to content

Conversation

@cyclops1982
Copy link

Might seem a bit strange, but let's say you store all your JS files in a
directory. Now, you want to host your service-worker.js in the root (for
scope reasons). This will allow you to do addFile('/service-worker.js',
'./js/service-worker.js');

This basically is a little bit of url-rewriting for an individual file.

Patch is untested as on debian9 the string_view is in std::experimental.

It would be great if you (ahu) could review is this is actually the right way to do it.

Might seem a bit strange, but let's say you store all your JS files in a
directory. Now, you want to host your service-worker.js in the root (for
scope reasons). This will allow you to do addFile('/service-worker.js',
'./js/service-worker.js');

This basically is a little bit of url-rewriting for an individual file.

Patch is untested as on debian9 the string_view is in std::experimental.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant