diff --git a/babel.config.js b/babel.config.js index f3315bbd44..2e9a4a5ddb 100644 --- a/babel.config.js +++ b/babel.config.js @@ -4,6 +4,7 @@ module.exports = { "@babel/preset-env", { corejs: 3, + loose: true, // Loose mode for…of loops are 5× faster in Firefox useBuiltIns: "usage", }, ], diff --git a/static/js/bundles/common.js b/static/js/bundles/common.js index ffe04c178a..fca9df10f2 100644 --- a/static/js/bundles/common.js +++ b/static/js/bundles/common.js @@ -1,4 +1,5 @@ import "core-js/features/promise"; +import "core-js/features/symbol"; import "jquery/dist/jquery.js"; import "underscore/underscore.js"; import "../page_params.js"; diff --git a/static/js/unread.js b/static/js/unread.js index e7a4c90bbe..e8889833e9 100644 --- a/static/js/unread.js +++ b/static/js/unread.js @@ -297,7 +297,7 @@ exports.unread_topic_counter = (function () { return { pretty_name: topic_name, - message_id: Math.max(...msgs), + message_id: Math.max(...Array.from(msgs)), }; });