-
Notifications
You must be signed in to change notification settings - Fork 504
Open
Open
Copy link
Labels
code taskdependenciesPull requests that update a dependency filePull requests that update a dependency filehelp wantedNeeds a volunteer to claim to move forwardNeeds a volunteer to claim to move forward
Description
Describe the bug
DSpace uses several dependencies that are packaged as AMD or CommonJS modules, which leads to several warnings during the build process. For example:
Warning: dspace-angular/src/app/core/services/client-cookie.service.ts depends on 'js-cookie'. CommonJS or AMD dependencies can cause optimization bailouts.
For more info see: https://angular.dev/tools/cli/build#configuring-commonjs-dependenciesThis can lead to sub-optimal tree shaking in Webpack. Using ES Module (ESM) versions of these dependencies where possible allows Webpack to eliminate unused code, reducing bundle size and improving performance.
The list of dependencies causing these warnings is currently:
- js-cookie
- orejime/dist/orejime
- leaflet
- leaflet-providers
- leaflet.markercluster
- date-fns-tz
Some of these may have drop-in replacements, while others may require code changes.
Related work
Part of the work was completed for DSpace 9 in #4098. There is also more discussion in #4095.
Metadata
Metadata
Assignees
Labels
code taskdependenciesPull requests that update a dependency filePull requests that update a dependency filehelp wantedNeeds a volunteer to claim to move forwardNeeds a volunteer to claim to move forward
Type
Projects
Status
📋 To Do