type declaration files for 'workbox-build'
Brought to you by:
tomkozak
Originally created by: Mister-Hope
Is there a type declaration files for 'workbox-build'?
I can only find these
Originally posted by: jeffposnick
There isn't, no.
In Workbox v5, we migrated the runtime codebase to TypeScript, so there are native types for all of those interfaces.
The v5 build tools were not migrated to TypeScript, though. (This might happen in a future release.)
Something that might help is that https://github.com/GoogleChrome/workbox/pull/2320 adds proper JSDoc info for all of the options supported by the build tools in v5. Once that's merged, I think it's a fairly straightforward process to either consume the JSDoc from an IDE, or generate standalone TypeScript typings from the JSDoc.
Originally posted by: Mister-Hope
Glad you merged that PR and release V5, hope you can make the type declaration files for it soon.
Related
Tickets:
#2320Originally posted by: IlCallo
Are
workbox-webpack-pluginoptions the same ofworkbox-build? Are their types still missing too? Quasar framework uses workbox under the hood to power it's PWA mode and we hoped v5 would bring types forworkbox-webpack-pluginconfiguration object tooOriginally posted by: jeffposnick
There are some differences in the options between
workbox-webpack-pluginandworkbox-build.What's new in v5 is that there is proper JSDoc for both of those interfaces.
Hopefully the JSDoc can help with autocompletion in IDEs, and I believe there are some tools for generating unofficial typing info from JSDoc as well.
Rewriting the build tools in TypeScript may happen at some point, but for v5, we focused on rewriting the runtime libraries.
Ticket changed by: jeffposnick
Originally posted by: jeffposnick
workbox-buildTypeScript migration is tracked in [#2477]. I'm closing this in favor of that.Related
Tickets:
#2477