{"record":{"id":"2a320b2dc178b28a","repo":"facebook/react","slug":"275","errorCode":"275","errorMessage":"The current renderer does not support mutation. This error is likely caused by a bug in React. Please file an issue.","messagePattern":"The current renderer does not support mutation\\. This error is likely caused by a bug in React\\. Please file an issue\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/react-reconciler/src/ReactFiberConfigWithNoMutation.js","lineNumber":14,"sourceCode":"/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * @flow\n */\n\n// Renderers that don't support mutation\n// can re-export everything from this module.\n\nfunction shim(...args: any): empty {\n  throw new Error(\n    'The current renderer does not support mutation. ' +\n      'This error is likely caused by a bug in React. ' +\n      'Please file an issue.',\n  );\n}\n\n// Mutation (when unsupported)\nexport const supportsMutation = false;\nexport const cloneMutableInstance = shim;\nexport const cloneMutableTextInstance = shim;\nexport const appendChild = shim;\nexport const appendChildToContainer = shim;\nexport const commitTextUpdate = shim;\nexport const commitMount = shim;\nexport const commitUpdate = shim;\nexport const insertBefore = shim;\nexport const insertInContainerBefore = shim;\nexport const removeChild = shim;","sourceCodeStart":1,"sourceCodeEnd":32,"githubUrl":"https://github.com/facebook/react/blob/eafeac097ba51e1eab809c07102126bd5f8e5425/packages/react-reconciler/src/ReactFiberConfigWithNoMutation.js#L1-L32","documentation":"Renderers that don't mutate the host tree re-export ReactFiberConfigWithNoMutation: every mutation commit hook (appendChild, commitUpdate, removeChild, insertBefore, clearContainer, etc.) is a throwing shim and `supportsMutation = false`. The reconciler calls these during the mutation phase of a commit; seeing this error means a mutating commit ran against a non-mutating host config.","triggerScenarios":"A container is committed in mutation mode while the resolved host config re-exports NoMutation — e.g. a custom renderer built from a no-mutation config (persistent or test-style renderer) whose root is driven through the default mutation commit path.","commonSituations":"Custom renderer authors (react-nil-style renderers, PDF/canvas targets) re-exporting the no-mutation shim without providing their own commit implementation; or miswired configs where the wrong host config got aliased.","solutions":["Implement the mutation methods in your host config (appendChild, commitUpdate, removeChild, ...) matching your target.","If your renderer is persistent, make sure you use the persistence commit path and implement the persistence hooks instead.","Double-check which host config your build actually resolves (aliases, jest moduleNameMapper) — a wrong alias is a common cause."],"exampleFix":"// before: no mutation support\nexport * from 'react-reconciler/src/ReactFiberConfigWithNoMutation';\n\n// after: implement the methods your target needs\nexport const supportsMutation = true;\nexport function appendChild(parent, child) {\n  parent.children.push(child);\n}\nexport function removeChild(parent, child) {\n  parent.children = parent.children.filter(c => c !== child);\n}","handlingStrategy":"validation","validationCode":"// Renderer smoke test: run one mount+update+unmount per config before shipping\nconst root = ReactReconcilerReconciler.createContainer(container, 0, null, false, null);\nReactReconcilerReconciler.updateContainer(<App />, root, null, null); // throws early if shims are wired in","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Custom renderers: implement every mutation hook your commit path touches (appendChild, commitUpdate, removeChild...)","Verify which host config your aliases actually resolve in tests and builds","Keep a checklist of required host config exports when upgrading react-reconciler"],"tags":["mutation","custom-renderer","renderer-capability","commit-phase"],"backgroundTag":"renderer-capability-unsupported","analyzedSha":"eafeac097ba51e1eab809c07102126bd5f8e5425","analyzedAt":"2026-08-21T22:01:08.818Z","schemaVersion":2},"datasetVersion":"2026-08-21T23:17:16.201Z"}