question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

next/script eslint-plugin-next Cannot read property 'name' of undefined

See original GitHub issue

What version of Next.js are you using?

12.0.7

What version of Node.js are you using?

14.17.5

What browser are you using?

Chrome

What operating system are you using?

Windows

How are you deploying your application?

next start

Describe the Bug

When I’m using spread operator for <Script> tag, I got an error:

    at \node_modules\@next\eslint-plugin-next\lib\rules\inline-script-id.js:34:43
    at Array.some (<anonymous>)
    at JSXElement (\node_modules\@next\eslint-plugin-next\lib\rules\inline-script-id.js:33:22)
    at \node_modules\eslint\lib\linter\safe-emitter.js:45:58
    at Array.forEach (<anonymous>)
    at Object.emit (\node_modules\eslint\lib\linter\safe-emitter.js:45:38)
    at NodeEventGenerator.applySelector (\node_modules\eslint\lib\linter\node-event-generator.js:293:26)
    at NodeEventGenerator.applySelectors (\node_modules\eslint\lib\linter\node-event-generator.js:322:22)
    at NodeEventGenerator.enterNode (\node_modules\eslint\lib\linter\node-event-generator.js:336:14)
    at CodePathAnalyzer.enterNode (\node_modules\eslint\lib\linter\code-path-analysis\code-path-analyzer.js:711:23)

Expected Behavior

I expected to have no eslint errors

To Reproduce

<Script {...{ strategy: 'beforeInteractive' }} id={'test'} />

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:12 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
balazsorban44commented, Dec 12, 2021

@Xunnamius I believe that is already fixed #32251

1reaction
josharshcommented, Dec 7, 2021

@balazsorban44 are you picking this up? (If not, I would like to give a shot)

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeError: Cannot read property 'name' of undefined discord.js
TypeError : Cannot read property 'name' of undefined. It is saying that there is no name property in the message.guild collection, put a...
Read more >
Basic Features: ESLint - Next.js
js provides an ESLint plugin, eslint-plugin-next , already bundled within the base configuration that makes it possible to catch common issues and problems...
Read more >
Error Cannot read property 'name' of undefined in Spectrum ...
Learn how to resolve error Cannot read property 'name' of undefined in Spectrum Spatial Analyst v12.1 There's a technology difference between SSA v8.0...
Read more >
TypeError: Cannot read property 'name' of undefined
The problem seems coming from the implementation of the rule S2234. Would it possible to provide me with a reproducer triggering the issue...
Read more >
5.2 - TypeError: Cannot read property 'name' of undefined
I get an error but still get a pass. Also no print out. What am I doing wrong please. // Our Person constructor...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found