BannerPlugin.d.ts 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /**
  2. * This file was automatically generated.
  3. * DO NOT MODIFY BY HAND.
  4. * Run `yarn special-lint-fix` to update
  5. */
  6. export type BannerPluginArgument =
  7. | BannerPluginOptions
  8. | BannerFunction
  9. | string;
  10. /**
  11. * The banner as function, it will be wrapped in a comment
  12. */
  13. export type BannerFunction = (
  14. data: {
  15. hash: string;
  16. chunk: import("../../lib/Chunk");
  17. filename: string;
  18. basename: string;
  19. query: string;
  20. }
  21. ) => string;
  22. export type Rules = Rule[] | Rule;
  23. export type Rule = RegExp | string;
  24. export interface BannerPluginOptions {
  25. /**
  26. * Specifies the banner
  27. */
  28. banner: BannerFunction | string;
  29. /**
  30. * If true, the banner will only be added to the entry chunks
  31. */
  32. entryOnly?: boolean;
  33. /**
  34. * Exclude all modules matching any of these conditions
  35. */
  36. exclude?: Rules;
  37. /**
  38. * Include all modules matching any of these conditions
  39. */
  40. include?: Rules;
  41. /**
  42. * If true, banner will not be wrapped in a comment
  43. */
  44. raw?: boolean;
  45. /**
  46. * Include all modules that pass test assertion
  47. */
  48. test?: Rules;
  49. }