Home / File/ astro.config.mjs — astro Source File

astro.config.mjs — astro Source File

Architecture documentation for astro.config.mjs, a javascript file in the astro codebase. 2 imports, 0 dependents.

File javascript 2 imports

Entity Profile

Dependency Diagram

graph LR
  2d0bdafb_4131_164d_5401_85e52f1c16d9["astro.config.mjs"]
  d9a92db9_c95e_9165_13ac_24b3d859d946["node:url"]
  2d0bdafb_4131_164d_5401_85e52f1c16d9 --> d9a92db9_c95e_9165_13ac_24b3d859d946
  3b10c06c_a805_be1f_3a3d_1f00ea858ef5["config"]
  2d0bdafb_4131_164d_5401_85e52f1c16d9 --> 3b10c06c_a805_be1f_3a3d_1f00ea858ef5
  style 2d0bdafb_4131_164d_5401_85e52f1c16d9 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import {fileURLToPath} from "node:url";
import {defineConfig} from "astro/config";

export default defineConfig({
	integrations: [
		{
			name: 'my-middleware',
			hooks: {
				'astro:config:setup':({ addMiddleware }) => {
					addMiddleware({
						entrypoint: fileURLToPath(new URL('./integration-middleware-pre.js', import.meta.url)),
						order: 'pre'
					});

					addMiddleware({
						entrypoint: fileURLToPath(new URL('./integration-middleware-post.js', import.meta.url)),
						order: 'post'
					});

					addMiddleware({
						entrypoint: new URL('./integration-middleware-url.js', import.meta.url),
						order: 'post'
					});
				}
			}
		}
	]
});

Dependencies

  • config
  • node:url

Frequently Asked Questions

What does astro.config.mjs do?
astro.config.mjs is a source file in the astro codebase, written in javascript.
What does astro.config.mjs depend on?
astro.config.mjs imports 2 module(s): config, node:url.
Where is astro.config.mjs in the architecture?
astro.config.mjs is located at packages/astro/test/fixtures/middleware-no-user-middleware/astro.config.mjs (directory: packages/astro/test/fixtures/middleware-no-user-middleware).

Analyze Your Own Codebase

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

Try Supermodel Free