Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GenerateSW does not support method option in runtimeCaching #1636

Closed
chrisdns opened this issue Sep 15, 2018 · 1 comment
Closed

GenerateSW does not support method option in runtimeCaching #1636

chrisdns opened this issue Sep 15, 2018 · 1 comment
Labels
Bug An issue with our existing, production codebase. workbox-build

Comments

@chrisdns
Copy link
Contributor

Library Affected:
workbox-build, workbox-webpack-plugin

Browser & Platform:
Google Chrome Version 69.0.3497.92 (Official Build) (64-bit)

Issue or Feature Request Description:
I would like to use POST method in runtimeCaching options from WorkboxPlugin.GenerateSW({ }) plugin instead of GET.

It is not possible at the moment to change the default method ; it leads to a validationError

ValidationError: child "runtimeCaching" fails because ["runtimeCaching" at position 0 fails because ["method" is not a supported parameter.]].

It should be possible to change default method, I can make a PR if you think this is relevant.

@jeffposnick
Copy link
Contributor

A PR would be appreciated—thanks!

This was just an oversight; there's already logic in place to read in the method, but the validation logic doesn't allow for it to be set, so I think that validation logic is the only thing that would need to change.

@jeffposnick jeffposnick added Bug An issue with our existing, production codebase. workbox-build labels Sep 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug An issue with our existing, production codebase. workbox-build
Projects
None yet
Development

No branches or pull requests

2 participants