plugins-index.d.mts 977 B

123456789101112131415161718192021222324252627282930313233
  1. import { m as BindingReplacePluginConfig } from "./shared/binding-DUEnSb0A.mjs";
  2. import { N as BuiltinPlugin } from "./shared/define-config-DhJZwTRw.mjs";
  3. import { t as esmExternalRequirePlugin } from "./shared/constructors-DYemMpPL.mjs";
  4. //#region src/builtin-plugin/replace-plugin.d.ts
  5. /**
  6. * Replaces targeted strings in files while bundling.
  7. *
  8. * @example
  9. * **Basic usage**
  10. * ```js
  11. * replacePlugin({
  12. * 'process.env.NODE_ENV': JSON.stringify('production'),
  13. * __buildVersion: 15
  14. * })
  15. * ```
  16. * @example
  17. * **With options**
  18. * ```js
  19. * replacePlugin({
  20. * 'process.env.NODE_ENV': JSON.stringify('production'),
  21. * __buildVersion: 15
  22. * }, {
  23. * preventAssignment: false,
  24. * })
  25. * ```
  26. *
  27. * @see https://rolldown.rs/builtin-plugins/replace
  28. * @category Builtin Plugins
  29. */
  30. declare function replacePlugin(values?: BindingReplacePluginConfig["values"], options?: Omit<BindingReplacePluginConfig, "values">): BuiltinPlugin;
  31. //#endregion
  32. export { esmExternalRequirePlugin, replacePlugin };