Uncaught TypeError: Cannot read property 'split' of undefined in browser.js line 22 prevails
See original GitHub issueUsing v.3.0.9, I still encounter the Uncaught TypeError: Cannot read property 'split' of undefined
error in browser.js
, line 22
.
├─ pbkdf2@3.0.9
│ └─ create-hmac@^1.1.2
I am using the pbkdf2 library with webpack without browserify.
A workaround is to import var process = require('process')
at the top of the browser.js
file.
Do you have ideas how we could get a proper solution for this issue?
Issue Analytics
- State:
- Created 7 years ago
- Comments:11 (4 by maintainers)
Top Results From Across the Web
Uncaught TypeError: Cannot read property 'split' of undefined
Your question answers itself ;) If og_date contains the date, it's probably a string, so og_date.value is undefined.
Read more >How to Prevent cannot read property split of ... - Gopi Gorantala
The "cannot read property 'split' of undefined" error occurs when trying to call split() method on a variable that stores an undefined value....
Read more >Cannot Read Property 'split' of Undefined - freeCodeCamp
it will throw the TypeError: Cannot read property 'split' of undefined error. The split method. When split is called on a string, it...
Read more >How to prevent cannot read property split of ... - Meticulous
Split () is a JavaScript string method that splits a string into an array of substrings without mutating the original string.
Read more >TypeError: Cannot read property 'split' of undefined - JavaScript
So the argument word is coming in as undefined and therefore you can't run split() on it. You can either make sure it...
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
Still an issue in 2021 (Angular) , adding
var process = require('process')
doesn’t help, any other elegant solutions?I just tried to reproduce the issue again in an example, and realized I had accidentally overwritten the process option with
webpack.DefinePlugin
. Sorry for any inconvenience this caused and thanks for your support!