Drop IE11 support and CommonJS?

Open
#3,103 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
babel, javascript, react

Research direction

Start with babel.config.js at the referenced target settings, then inspect the npm package paths under /components, /module/components, and /lib/components and the listed bundled files. Determine the supported browser targets and whether the package should consolidate on ESM; done means the agreed output formats and bundle set are updated without the unnecessary duplicates.

Written by the indexing model from the issue text.

Description

IE11 was officially retired by Microsoft in June 2022. Would it be possible to update the list of supported targets here?

https://github.com/salesforce/design-system-react/blob/ccbca0673b00a79a96745b590974c9c262db2e43/babel.config.js#L7-L8

Similarly, the library package on npm includes three different unbundled versions of each component:

  1. Source code in /components
  2. Compiled ES modules in /module/components
  3. Compiled CommonJS modules in /lib/components

There also seem to be several bundled versions of the entire library:

  1. design-system-react-components.js
  2. design-system-react-components.min.js
  3. design-system-react.js
  4. design-system-react.min.js

While decreasing the size of the npm package would certainly be nice, the main reason that it would be nice to consolidate on ESM would be to avoid accidentally duplicating versions of these components in apps which still use a mix of ESM and CommonJS. This is a pretty common footgun which results in increased bundle size as well as bugs when "stateful" things like context or settings are duplicated.

Dominant language
JavaScript
Stars
994
Forks
444
Avg merge
3d 23h
Merged PRs (30d)
44

Getting set up

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.

More from salesforce/design-system-react

All issues in salesforce/design-system-react

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.