TypeError: Cannot read property 'browserField' of undefined
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 119
- Forks
- 11
- PR merge metrics
- No merged PRs in 30d
Description
I have the following in my gulpfile.js:
return browserify(entryPoint, { debug: isDevelopment })
.transform('esmify')
Which leads to the following error:
TypeError: Cannot read property 'browserField' of undefined
at module.exports (C:\Users\leaha\Desktop\git\design-system\node_modules\esmify\esmify.js:20:24)
at nr (C:\Users\leaha\Desktop\git\design-system\node_modules\module-deps\index.js:315:23)
at onfile (C:\Users\leaha\Desktop\git\design-system\node_modules\resolve\lib\async.js:146:21)
at onex (C:\Users\leaha\Desktop\git\design-system\node_modules\resolve\lib\async.js:201:32)
at C:\Users\leaha\Desktop\git\design-system\node_modules\resolve\lib\async.js:13:20
at FSReqCallback.oncomplete (fs.js:193:5)
at FSReqCallback.callbackTrampoline (internal/async_hooks.js:131:17)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the error from the gulpfile.js browserify configuration, then inspect esmify/esmify.js at the reported line and the surrounding module-deps and resolve calls in the stack trace. A complete fix should prevent the browserField TypeError when the esmify transform runs, with the behavior verified against the reported setup.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100