Closed rbrundritt closed 3 years ago
@rbrundritt Thanks for the feedback. Given ADAL.js is no longer under active development, we won't be prioritizing enhancements like this. We highly suggest apps to move to MSAL.js: https://www.npmjs.com/package/@azure/msal-browser
I noticed that this library was fairly large. When looking through the source code I noticed there is a lot of room for optimizations that will help with the minification process. A couple of tips:
var self = this;
The variable will be minified to a single character and save you 3 characters per use of the "this" keyword.this.config
cache likevar config = self.config;
This will save 10 characters per per use.this.CONSTANTS.STORAGE
cache likevar = this.CONSTANTS.STORAGE;
This will save 19 characters per use.I'm sure there are some additional optimizations that can be made to help reduce the file size. I wouldn't be surprised if this could the file size could be cut by 30% or more.