swagger-api / swagger-api/swagger-ui

Build error Can't resolve 'readable-stream/writable.js'

Open
#6,673 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

type: support
Dominant language
JavaScript
Stars
29k
Forks
9.3k
Avg merge
2d 23h
Merged PRs (30d)
25

Description

which version of node to use ? I have tried with Node -14.x.x and 15.x.x and both failed to compile

Module not found: Error: Can't resolve 'readable-stream/writable.js' in '/node_modules/stream-browserify'
@ ./node_modules/stream-browserify/index.js 29:18-56
@ ./node_modules/swagger-ui-react/swagger-ui.js
@ ./node_modules/swagger-ui-react/index.js

Package referenced swagger-ui-react- 3.37.2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the swagger-ui-react 3.37.2 dependency path shown in the error, especially node_modules/stream-browserify and its reference to readable-stream/writable.js. Reproduce the compile with the reported Node 14.x.x and 15.x.x versions, then verify that the package builds without the module-not-found error.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
build-system, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.