Merge pull request #2531 from overleaf/ho-restore-lodash-2526

Revert "Reverts move from underscore to lodash"

GitOrigin-RevId: 1ea964d5c98a85f9490c0e731d6a68335df93c67
This commit is contained in:
Henry Oswald
2020-01-17 04:19:51 +00:00
committed by Copybot
parent 94e3051d2e
commit fe8ef3f08f
8 changed files with 11 additions and 1714 deletions
+3 -12
View File
@@ -167,11 +167,8 @@ module.exports = {
]
},
{
// Expose underscore global variable
test: path.join(
__dirname,
`frontend/js/vendor/libs/${PackageVersions.lib('underscore')}.js`
),
// Expose lodash global variable
test: require.resolve('lodash'),
use: [
{
loader: 'expose-loader',
@@ -257,11 +254,5 @@ module.exports = {
// to provide support for non-Latin characters
{ from: 'node_modules/pdfjs-dist/cmaps', to: 'js/cmaps' }
])
],
// If underscore is required by another dependency *don't* include in the
// bundle and use the relevant global variable instead
externals: {
underscore: '_'
}
]
}