astro/.changeset/odd-books-live.md
2023-08-01 16:00:39 +01:00

483 B
Raw Blame History

astro
minor

Integrations can now log messages using Astros built-in logger.

The logger is available to all hooks as an additional parameter:

import {AstroIntegration} from "./astro";

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