Home / File/ vite.config.js — vite Source File

vite.config.js — vite Source File

Architecture documentation for vite.config.js, a javascript file in the vite codebase. 3 imports, 0 dependents.

File javascript ViteCore ConfigEngine 3 imports 3 functions

Entity Profile

Dependency Diagram

graph LR
  4f18463e_0189_3a52_f9d6_673fd03d4b34["vite.config.js"]
  e6032fbc_44cf_58d6_868d_dd15106c18c5["node:fs"]
  4f18463e_0189_3a52_f9d6_673fd03d4b34 --> e6032fbc_44cf_58d6_868d_dd15106c18c5
  ad382781_051b_4f17_29a3_3e882464e6c0["node:module"]
  4f18463e_0189_3a52_f9d6_673fd03d4b34 --> ad382781_051b_4f17_29a3_3e882464e6c0
  54c37fea_4fe7_2693_71cb_1276b77f55f9["vite"]
  4f18463e_0189_3a52_f9d6_673fd03d4b34 --> 54c37fea_4fe7_2693_71cb_1276b77f55f9
  style 4f18463e_0189_3a52_f9d6_673fd03d4b34 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import fs from 'node:fs'
import module from 'node:module'
import { defineConfig } from 'vite'
const require = module.createRequire(import.meta.url)

export default defineConfig({
  define: {
    __VUE_PROD_HYDRATION_MISMATCH_DETAILS__: false,
  },
  resolve: {
    dedupe: ['react'],
    alias: {
      'node:url': 'url',
      '@vitejs/test-dep-alias-using-absolute-path':
        require.resolve('@vitejs/test-dep-alias-using-absolute-path'),
    },
  },
  optimizeDeps: {
    include: [
      '@vitejs/test-dep-linked-include',
      '@vitejs/test-nested-exclude > @vitejs/test-nested-include',
      '@vitejs/test-dep-cjs-external-package-omit-js-suffix',
      // will throw if optimized (should log warning instead)
      '@vitejs/test-non-optimizable-include',
      '@vitejs/test-dep-optimize-exports-with-glob/**/*',
      '@vitejs/test-dep-optimize-exports-with-root-glob/**/*.js',
      '@vitejs/test-dep-optimize-with-glob/**/*.js',
      '@vitejs/test-dep-cjs-with-external-deps',
      '@vitejs/test-dep-cjs-with-es-module-flag',
    ],
    exclude: [
      '@vitejs/test-nested-exclude',
      '@vitejs/test-dep-non-optimized',
      '@vitejs/test-dep-esm-external',
      'stream',
    ],
    rolldownOptions: {
      plugins: [
        {
          name: 'replace-a-file',
          load(id) {
            if (/dep-esbuild-plugin-transform(?:\\|\/)index\.js$/.test(id)) {
              return `export const hello = () => 'Hello from an esbuild plugin'`
            }
          },
        },
      ],
    },
    entries: ['index.html', 'unused-split-entry.js'],
  },

  build: {
    // to make tests faster
    minify: false,
  },

  plugins: [
    testVue(),
    notjs(),
    virtualModulePlugin(),
// ... (96 more lines)

Domain

Subdomains

Dependencies

  • node:fs
  • node:module
  • vite

Frequently Asked Questions

What does vite.config.js do?
vite.config.js is a source file in the vite codebase, written in javascript. It belongs to the ViteCore domain, ConfigEngine subdomain.
What functions are defined in vite.config.js?
vite.config.js defines 3 function(s): notjs, testVue, virtualModulePlugin.
What does vite.config.js depend on?
vite.config.js imports 3 module(s): node:fs, node:module, vite.
Where is vite.config.js in the architecture?
vite.config.js is located at playground/optimize-deps/vite.config.js (domain: ViteCore, subdomain: ConfigEngine, directory: playground/optimize-deps).

Analyze Your Own Codebase

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

Try Supermodel Free