mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Also list <form> in error message as possible culprit
This commit is contained in:
@@ -649,9 +649,10 @@ var ReactMount = {
|
||||
false,
|
||||
'findComponentRoot(..., %s): Unable to find element. This probably ' +
|
||||
'means the DOM was unexpectedly mutated (e.g., by the browser), ' +
|
||||
'usually due to forgetting a <tbody> when using tables, nesting <p> ' +
|
||||
'or <a> tags, or using non-SVG elements in an <svg> parent. Try ' +
|
||||
'inspecting the child nodes of the element with React ID `%s`.',
|
||||
'usually due to forgetting a <tbody> when using tables, nesting tags ' +
|
||||
'like <form>, <p>, or <a>, or using non-SVG elements in an <svg> ' +
|
||||
'parent. ' +
|
||||
'Try inspecting the child nodes of the element with React ID `%s`.',
|
||||
targetID,
|
||||
ReactMount.getID(ancestorNode)
|
||||
);
|
||||
|
||||
@@ -119,9 +119,9 @@ var DOMChildrenOperations = {
|
||||
'processUpdates(): Unable to find child %s of element. This ' +
|
||||
'probably means the DOM was unexpectedly mutated (e.g., by the ' +
|
||||
'browser), usually due to forgetting a <tbody> when using tables, ' +
|
||||
'nesting <p> or <a> tags, or using non-SVG elements in an <svg> '+
|
||||
'parent. Try inspecting the child nodes of the element with React ' +
|
||||
'ID `%s`.',
|
||||
'nesting tags like <form>, <p>, or <a>, or using non-SVG elements '+
|
||||
'in an <svg> parent. Try inspecting the child nodes of the element ' +
|
||||
'with React ID `%s`.',
|
||||
updatedIndex,
|
||||
parentID
|
||||
);
|
||||
|
||||
@@ -147,10 +147,10 @@ describe('ReactInstanceHandles', function() {
|
||||
'Invariant Violation: findComponentRoot(..., .0.1:0:junk): ' +
|
||||
'Unable to find element. This probably means the DOM was ' +
|
||||
'unexpectedly mutated (e.g., by the browser), usually due to ' +
|
||||
'forgetting a <tbody> when using tables, nesting <p> or <a> tags, ' +
|
||||
'or using non-SVG elements in an <svg> parent. Try inspecting the ' +
|
||||
'child nodes of the element with React ' +
|
||||
'ID `.0`.'
|
||||
'forgetting a <tbody> when using tables, nesting tags ' +
|
||||
'like <form>, <p>, or <a>, or using non-SVG elements in an <svg> ' +
|
||||
'parent. ' +
|
||||
'Try inspecting the child nodes of the element with React ID `.0`.'
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user