astro/.changeset/twelve-baboons-obey.md
2023-07-25 15:16:29 +01:00

422 B

astro
minor

Astro integrations now accept a logger. The logger is available to all hooks as an additional parameter:

// integration.js
export function myIntegration(): AstroIntegration {
    return {
        name: "my-integration",
        hooks: {
            "astro:config:done": (options, { logger }) => {
                logger.info("Configure integration...");
            }
        }
    }
}