TypeError: Cannot read property 'raw' of undefined
See original GitHub issueLooks like @putout/plugin-regexp can’t handle named capturing groups.
const regexp = /(?<foo>a)/;
gives the following error:
TypeError: Cannot read property 'raw' of undefined
Occurred while linting /home/user/example.js:1
at RegExpLiteral (/home/user/node_modules/@putout/plugin-regexp/lib/remove-useless-group/index.js:14:38)
ESLint: 7.30.0 putout: 18.4.0 eslint-plugin-putout: 8.1.0 @putout/plugin-regexp: 2.3.3
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:9 (4 by maintainers)
Top Results From Across the Web
ReactJS - TypeError: Cannot read property 'raw' of undefined
This happens because in the first render, this.state.photo is an array constructor(props) { super(props); this.state = { photo: [], photoId: ...
Read more >Cannot Read Property of Undefined in JavaScript - Rollbar
TypeError: Cannot read property of undefined occurs when a property is read or a function is called on an undefined variable.
Read more >Unhandled rejection TypeError: Cannot read property 'raw' of ...
For anybody else, I fixed it by wrapping trx.raw in a function instead of passing trx.raw directly to my callback.
Read more >Topic: Cannot read property 'raw' of undefined - WordPress.com
I have just started trying to set up my site today using the Mayland theme, and I keep getting the error 'Cannot read...
Read more >Cannot read property 'raw' of undefined-Reactjs - appsloveworld
Coding example for the question ReactJS: Cannot read property 'raw' of undefined-Reactjs.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It works now, thank you!
Fixed with 54e1145, landed in
@putout/compare@7.6.1
🎉 . Is it works for you?