module-registry.d.ts 1.0 KB

123456789101112131415161718192021222324252627282930313233
  1. /**
  2. * Class for keeping track of which Workbox modules are used by the generated
  3. * service worker script.
  4. *
  5. * @private
  6. */
  7. export declare class ModuleRegistry {
  8. private readonly _modulesUsed;
  9. /**
  10. * @private
  11. */
  12. constructor();
  13. /**
  14. * @return {Array<string>} A list of all of the import statements that are
  15. * needed for the modules being used.
  16. * @private
  17. */
  18. getImportStatements(): Array<string>;
  19. /**
  20. * @param {string} pkg The workbox package that the module belongs to.
  21. * @param {string} moduleName The name of the module to import.
  22. * @return {string} The local variable name that corresponds to that module.
  23. * @private
  24. */
  25. getLocalName(pkg: string, moduleName: string): string;
  26. /**
  27. * @param {string} pkg The workbox package that the module belongs to.
  28. * @param {string} moduleName The name of the module to import.
  29. * @return {string} The local variable name that corresponds to that module.
  30. * @private
  31. */
  32. use(pkg: string, moduleName: string): string;
  33. }