Home / Function/ resolveRollupOptions() — vite Function Reference

resolveRollupOptions() — vite Function Reference

Architecture documentation for the resolveRollupOptions() function in pluginContainer.ts from the vite codebase.

Entity Profile

Dependency Diagram

graph TD
  bb020589_65d7_d25c_54ff_9633445ea428["resolveRollupOptions()"]
  285b1044_dd20_6f59_7cf5_0ad094eeacee["EnvironmentPluginContainer"]
  bb020589_65d7_d25c_54ff_9633445ea428 -->|defined in| 285b1044_dd20_6f59_7cf5_0ad094eeacee
  1abc446c_e46b_1be0_59f5_51bdfded0f6c["createEnvironmentPluginContainer()"]
  1abc446c_e46b_1be0_59f5_51bdfded0f6c -->|calls| bb020589_65d7_d25c_54ff_9633445ea428
  740b85c6_7fbd_cec6_1dc6_e19314ddecba["handleHookPromise()"]
  bb020589_65d7_d25c_54ff_9633445ea428 -->|calls| 740b85c6_7fbd_cec6_1dc6_e19314ddecba
  c42acd29_f3d2_c03f_de55_553d650a5fbf["throwClosedServerError()"]
  bb020589_65d7_d25c_54ff_9633445ea428 -->|calls| c42acd29_f3d2_c03f_de55_553d650a5fbf
  style bb020589_65d7_d25c_54ff_9633445ea428 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/vite/src/node/server/pluginContainer.ts lines 279–294

  async resolveRollupOptions(): Promise<InputOptions> {
    if (!this._resolvedRollupOptions) {
      let options = this.environment.config.build.rollupOptions
      for (const optionsHook of this.getSortedPluginHooks('options')) {
        if (this._closed) {
          throwClosedServerError()
        }
        options =
          (await this.handleHookPromise(
            optionsHook.call(this.minimalContext, options),
          )) || options
      }
      this._resolvedRollupOptions = options
    }
    return this._resolvedRollupOptions
  }

Domain

Subdomains

Frequently Asked Questions

What does resolveRollupOptions() do?
resolveRollupOptions() is a function in the vite codebase, defined in packages/vite/src/node/server/pluginContainer.ts.
Where is resolveRollupOptions() defined?
resolveRollupOptions() is defined in packages/vite/src/node/server/pluginContainer.ts at line 279.
What does resolveRollupOptions() call?
resolveRollupOptions() calls 2 function(s): handleHookPromise, throwClosedServerError.
What calls resolveRollupOptions()?
resolveRollupOptions() is called by 1 function(s): createEnvironmentPluginContainer.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free