fix: clarify error message

closes #10109
pull/10233/head
Simon Holthausen 11 months ago
parent 0071e0252a
commit a6797614ef

@ -78,7 +78,7 @@ const parse = {
* @param {string} reason * @param {string} reason
*/ */
'invalid-closing-tag-after-autoclose': (name, reason) => 'invalid-closing-tag-after-autoclose': (name, reason) =>
`</${name}> attempted to close element that was already automatically closed by <${reason}>`, `</${name}> attempted to close element that was already automatically closed by <${reason}> (cannot nest <${reason}> inside <${name}>)`,
'invalid-dollar-binding': () => 'invalid-dollar-binding': () =>
`The $ name is reserved, and cannot be used for variables and imports`, `The $ name is reserved, and cannot be used for variables and imports`,
'invalid-dollar-prefix': () => 'invalid-dollar-prefix': () =>

@ -3,7 +3,8 @@ import { test } from '../../test';
export default test({ export default test({
error: { error: {
code: 'invalid-closing-tag-after-autoclose', code: 'invalid-closing-tag-after-autoclose',
message: '</p> attempted to close element that was already automatically closed by <pre>', message:
'</p> attempted to close element that was already automatically closed by <pre> (cannot nest <pre> inside <p>',
position: [24, 24] position: [24, 24]
} }
}); });

Loading…
Cancel
Save