withastro/astro · error · Error
Integration ${colors.bold(integration.name)} has an unnamed
Error message
Integration ${colors.bold(integration.name)} has an unnamed renderer. What it means
During `astro:config:setup`, an integration can register renderers with `addRenderer(renderer)`. Astro requires every renderer to have a `name` (used for logging, error messages, and renderer resolution) and throws this plain Error from the addRenderer callback when `renderer.name` is falsy.
Source
Thrown at packages/astro/src/integrations/hooks.ts:229
* import.meta.env.production ? compress() : null
* ]
* ```
*/
let isLoggerUpdated = false;
const { integrationLogger } = await runHookInternal({
integration,
hookName: 'astro:config:setup',
logger,
params: () => {
const hooks: Omit<HookParameters<'astro:config:setup'>, 'logger'> = {
config: updatedConfig,
command,
isRestart,
addRenderer(renderer: AstroRenderer) {
if (!renderer.name) {
throw new Error(
`Integration ${colors.bold(integration.name)} has an unnamed renderer.`,
);
}
if (!renderer.serverEntrypoint) {
throw new Error(
`Renderer ${colors.bold(renderer.name)} does not provide a serverEntrypoint.`,
);
}
if (renderer.name === 'astro:jsx') {
astroJSXRenderer = renderer;
} else {
updatedSettings.renderers.push(renderer);
}
},
injectScript: (stage, content) => {
updatedSettings.scripts.push({ stage, content });View on GitHub (pinned to 52e6c34790)
Solutions
- Give the renderer a stable name: addRenderer({ name: '@myorg/solid', serverEntrypoint, ... }).
- Type the argument as AstroRenderer so TypeScript flags missing fields before runtime.
- If this fires from a dependency, report it to the integration - the fix belongs in its addRenderer call.
Example fix
// before
addRenderer({ serverEntrypoint: '@myorg/solid/server.js', clientEntrypoint: '@myorg/solid/client.js' });
// after
addRenderer({
name: '@myorg/solid',
serverEntrypoint: '@myorg/solid/server.js',
clientEntrypoint: '@myorg/solid/client.js',
}); Defensive patterns
Strategy: validation
Validate before calling
// before calling addRenderer in your integration
if (!renderer.name || typeof renderer.name !== 'string') {
throw new Error('renderer.name is required');
}
addRenderer(renderer); Type guard
import type { AstroRenderer } from 'astro';
function isCompleteRenderer(r: Partial<AstroRenderer>): r is AstroRenderer {
return typeof r.name === 'string' && !!r.serverEntrypoint;
} Prevention
- Type renderer objects as AstroRenderer so missing required fields fail at compile time.
- Keep a checklist integration test that registers the renderer against a minimal settings object.
- Prefer vendor-prefixed renderer names to avoid ambiguity in logs and errors.
When it happens
Trigger: An integration calling addRenderer({ serverEntrypoint, ... }) without a name property; a renderer object built conditionally where name can be undefined; refactoring a renderer integration and dropping the name field.
Common situations: Authoring a framework-renderer integration; copying a partial renderer config from docs or another integration; type assertions hiding a missing required field.
Related errors
- Renderer ${colors.bold(renderer.name)} does not provide a se
- Integration ${colors.bold(integrationName)} is injecting a t
- The "${integration.name}" integration is trying to add the "
- The "${integration.name}" integration is trying to add middl
- Integration "${maybeConflictingIntegration}" conflicts with
AI-assisted analysis of withastro/astro@52e6c34790 (2026-08-18).
Data as JSON: /api/errors/d1a068928a21bac1.
Report an issue: GitHub.