-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ES6 export option for package @azure/msal-common #5443
Comments
Closing as duplicate of #5724 |
@bmahall This isn't a dupe because this is concerning a different package (msal-common vs msal-browser). |
Yes, we have plans to, no decided deadline yet though. Will reopen this to track. cc @EmLauber |
A beta of the v3 version of msal-browser and beta of msal-react v2 are released which should be exporting ES2020 modules. Can you try that out and let us know if that resolves this issue? Thanks! |
Closing as msal-browser 3.0.0 and msal-common 14.0.0 are now released and include these changes. |
Core Library
MSAL.js v2 (@azure/msal-browser)
Wrapper Library
Not Applicable
Public or Confidential Client?
Public
Description
Related to #5274 #5274
Currently, @azure/msal-common does not ship an ESM build of the library. That means that tree-shaking is not possible for consumers of @azure/msal-common. With tree-shaking, we could significantly reduce the bundle size of consumer projects, including the OneNote Meeting Notes application. msal-common is currently one of the largest contributors to our bundle at around 121 KB parsed.
Given that the current recommendation for the size of an entry point bundle is 244KB according to webpack, this represents half of size of a typical app entry point. With both msal-browser and msal-common together, we've already taken up 249KB, more than the recommended entry point bundle size, even without any app code whatsoever.
This is a bulky library and adding ES6 exports make a very big difference to many apps that use it.
Source
Internal (Microsoft)
The text was updated successfully, but these errors were encountered: