{"record":{"id":"0e3c6ffd3d8d99fb","repo":"withastro/astro","slug":"noclientonlyhint","errorCode":"NoClientOnlyHint","errorMessage":"Unable to render `${componentName}`. When using the `client:only` hydration strategy, Astro needs a hint to use the correct renderer.","messagePattern":"Unable to render `(.+?)`\\. When using the `client:only` hydration strategy, Astro needs a hint to use the correct renderer\\.","errorType":"exception","errorClass":"AstroError","httpStatus":null,"severity":"error","filePath":"packages/astro/src/runtime/server/render/component.ts","lineNumber":218,"sourceCode":"\t\t\t\t: metadata.hydrateArgs;\n\t\t\tif (clientOnlyValues.has(rendererName)) {\n\t\t\t\t// throw an error if provide correct client:only directive but not find the renderer\n\t\t\t\tconst plural = validRenderers.length > 1;\n\t\t\t\tthrow new AstroError({\n\t\t\t\t\t...AstroErrorData.NoMatchingRenderer,\n\t\t\t\t\tmessage: AstroErrorData.NoMatchingRenderer.message(\n\t\t\t\t\t\tmetadata.displayName,\n\t\t\t\t\t\tmetadata?.componentUrl?.split('.').pop(),\n\t\t\t\t\t\tplural,\n\t\t\t\t\t\tvalidRenderers.length,\n\t\t\t\t\t),\n\t\t\t\t\thint: AstroErrorData.NoMatchingRenderer.hint(\n\t\t\t\t\t\tformatList(probableRendererNames.map((r) => '`' + r + '`')),\n\t\t\t\t\t),\n\t\t\t\t});\n\t\t\t} else {\n\t\t\t\t// throw an error if an invalid hydration directive was provided\n\t\t\t\tthrow new AstroError({\n\t\t\t\t\t...AstroErrorData.NoClientOnlyHint,\n\t\t\t\t\tmessage: AstroErrorData.NoClientOnlyHint.message(metadata.displayName),\n\t\t\t\t\thint: AstroErrorData.NoClientOnlyHint.hint(\n\t\t\t\t\t\tprobableRendererNames.map((r) => r.replace('@astrojs/', '')).join('|'),\n\t\t\t\t\t),\n\t\t\t\t});\n\t\t\t}\n\t\t} else if (typeof Component !== 'string') {\n\t\t\tconst matchingRenderers = validRenderers.filter((r) =>\n\t\t\t\tprobableRendererNames.includes(r.name),\n\t\t\t);\n\t\t\tconst plural = validRenderers.length > 1;\n\t\t\tif (matchingRenderers.length === 0) {\n\t\t\t\tthrow new AstroError({\n\t\t\t\t\t...AstroErrorData.NoMatchingRenderer,\n\t\t\t\t\tmessage: AstroErrorData.NoMatchingRenderer.message(\n\t\t\t\t\t\tmetadata.displayName,\n\t\t\t\t\t\tmetadata?.componentUrl?.split('.').pop(),","sourceCodeStart":200,"sourceCodeEnd":236,"githubUrl":"https://github.com/withastro/astro/blob/d081033d5fe8e8a68c4bbbad4af9d2deb9c74bca/packages/astro/src/runtime/server/render/component.ts#L200-L236","documentation":"A `client:only` component was used, but the hint value (`metadata.hydrateArgs`) does not match any known framework/renderer. Because `client:only` skips server rendering, Astro cannot guess the renderer, so it throws `NoClientOnlyHint` suggesting the probable framework names (e.g. `react|preact|vue|svelte|solid`).","triggerScenarios":"`client:only` with no value at all; `client:only=\"raect\"` typo; `client:only=\"jquery\"` for a framework with no integration; value referencing a package name instead of the short framework key.","commonSituations":"Typing the framework name incorrectly; forgetting the hint entirely; using a custom renderer name that doesn't match the registered renderer's name.","solutions":["Provide a valid framework hint matching an installed renderer: `client:only=\"react\"`, `\"preact\"`, `\"vue\"`, `\"svelte\"`, `\"solid-js\"`.","Check spelling of the hint against the error's suggested list.","For a custom renderer, use the exact renderer `name` as the hint."],"exampleFix":"// before\n<Widget client:only=\"raect\" />\n\n// after\n<Widget client:only=\"react\" />","handlingStrategy":"validation","validationCode":"const CLIENT_ONLY_HINTS = ['react', 'preact', 'vue', 'svelte', 'solid-js'];\nfunction assertClientOnlyHint(hint: unknown): asserts hint is string {\n  if (typeof hint !== 'string' || !CLIENT_ONLY_HINTS.includes(hint)) {\n    throw new Error(`Invalid client:only hint '${String(hint)}'. Use one of: ${CLIENT_ONLY_HINTS.join(', ')}`);\n  }\n}","typeGuard":"const isValidClientOnlyHint = (hint: unknown): hint is string =>\n  typeof hint === 'string' && CLIENT_ONLY_HINTS.includes(hint);","tryCatchPattern":null,"preventionTips":["Always supply a framework hint on `client:only`.","Spell the framework name exactly (lowercase short name).","For custom renderers, use the registered renderer name as the hint."],"tags":["client-only","renderer","directives","hydration"],"backgroundTag":null,"analyzedSha":"d081033d5fe8e8a68c4bbbad4af9d2deb9c74bca","analyzedAt":"2026-08-12T13:37:29.035Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}