plotly / plotly/plotly.js

Webpack v5 compatibility issue (with workaround)

Open
#6,014 9 comments 5 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug infrastructure P2
Dominant language
JavaScript
Stars
18.3k
Forks
2k
Avg merge
2d 12h
Merged PRs (30d)
28

Description

With Webpack v5 I failed to run plotly.js, it requires additional stream and assert libs. The complete problem description is available here https://github.com/quasarframework/quasar/issues/11229

As I was pointed Webpack v5 removed the Nodejs polyfills for the web client builds. It seems that plotly.js for the web client rely on Nodejs API , and I get errors saying that some packages are missing. These probably need to be addressed by the plotly.js communty.

For users, if you just want to run your app/website (with a bit of risk), then you can manually install node-polyfill-webpack-plugin which solves the problem.

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 by reproducing a plotly.js web client build with Webpack v5 and review the linked Quasar issue for the complete error details. Investigate the reported missing stream and assert libraries and compare the result with the node-polyfill-webpack-plugin workaround. The issue does not name a repository file or test, and its desired fix is not defined beyond resolving the compatibility problem.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, webpack
Domain
build-system, data-visualization, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 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.