File tree Expand file tree Collapse file tree 5 files changed +10
-10
lines changed
tests/specs/nursery/useInlineScriptId Expand file tree Collapse file tree 5 files changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -150,11 +150,11 @@ impl Rule for UseInlineScriptId {
150150 rule_category ! ( ) ,
151151 state,
152152 markup ! {
153- "" <Emphasis >"next/script" </Emphasis >" components with inline content or `dangerouslySetInnerHTML` must specify " <Emphasis >"id" </Emphasis >" attribute."
153+ "" <Emphasis >"next/script" </Emphasis >" components have inline content or `dangerouslySetInnerHTML` without " <Emphasis >"id" </Emphasis >" attribute."
154154 } ,
155155 )
156156 . note ( markup ! (
157- "Without id attribute, Next.js cannot correctly track inline scripts and this can cause performance issues."
157+ "Next.js requires " < Emphasis > "id" </ Emphasis > " attribute to track and optimize inline scripts. Without it, performance issues may occur ."
158158 ) )
159159 . note ( markup ! {
160160 "See the " <Hyperlink href="https://nextjs.org/docs/messages/inline-script-id" >"Next.js docs" </Hyperlink >" for more details."
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ export default function Page() {
1919` ` `
2020invalid-01.jsx:6:5 lint/nursery/useInlineScriptId ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
2121
22- × next/script components with inline content or ` dangerouslySetInnerHTML ` must specify id attribute.
22+ × next/script components have inline content or ` dangerouslySetInnerHTML ` without id attribute.
2323
2424 4 │ export default function Page() {
2525 5 │ return (
@@ -28,7 +28,7 @@ invalid-01.jsx:6:5 lint/nursery/useInlineScriptId ━━━━━━━━━━
2828 7 │ )
2929 8 │ }
3030
31- i Without id attribute, Next.js cannot correctly track inline scripts and this can cause performance issues.
31+ i Next.js requires id attribute to track and optimize inline scripts. Without it, performance issues may occur .
3232
3333 i See the Next.js docs for more details.
3434
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ export default function Page() {
1919` ` `
2020invalid-02.jsx:6:5 lint/nursery/useInlineScriptId ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
2121
22- × next/script components with inline content or ` dangerouslySetInnerHTML ` must specify id attribute.
22+ × next/script components have inline content or ` dangerouslySetInnerHTML ` without id attribute.
2323
2424 4 │ export default function Page() {
2525 5 │ return (
@@ -28,7 +28,7 @@ invalid-02.jsx:6:5 lint/nursery/useInlineScriptId ━━━━━━━━━━
2828 7 │ )
2929 8 │ }
3030
31- i Without id attribute, Next.js cannot correctly track inline scripts and this can cause performance issues.
31+ i Next.js requires id attribute to track and optimize inline scripts. Without it, performance issues may occur .
3232
3333 i See the Next.js docs for more details.
3434
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ export default function Page() {
2020` ` `
2121invalid-03.jsx:7:5 lint/nursery/useInlineScriptId ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
2222
23- × next/script components with inline content or ` dangerouslySetInnerHTML ` must specify id attribute.
23+ × next/script components have inline content or ` dangerouslySetInnerHTML ` without id attribute.
2424
2525 5 │ const props = { strategy : " beforeInteractive" } ;
2626 6 │ return (
@@ -29,7 +29,7 @@ invalid-03.jsx:7:5 lint/nursery/useInlineScriptId ━━━━━━━━━━
2929 8 │ )
3030 9 │ }
3131
32- i Without id attribute, Next.js cannot correctly track inline scripts and this can cause performance issues.
32+ i Next.js requires id attribute to track and optimize inline scripts. Without it, performance issues may occur .
3333
3434 i See the Next.js docs for more details.
3535
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ export default function Page() {
1919` ` `
2020invalid-04.jsx:6:5 lint/nursery/useInlineScriptId ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
2121
22- × next/script components with inline content or ` dangerouslySetInnerHTML ` must specify id attribute.
22+ × next/script components have inline content or ` dangerouslySetInnerHTML ` without id attribute.
2323
2424 4 │ export default function Page() {
2525 5 │ return (
@@ -28,7 +28,7 @@ invalid-04.jsx:6:5 lint/nursery/useInlineScriptId ━━━━━━━━━━
2828 7 │ )
2929 8 │ }
3030
31- i Without id attribute, Next.js cannot correctly track inline scripts and this can cause performance issues.
31+ i Next.js requires id attribute to track and optimize inline scripts. Without it, performance issues may occur .
3232
3333 i See the Next.js docs for more details.
3434
You can’t perform that action at this time.
0 commit comments