This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| npm install auth0-js@9.13.4 auth0-lock@11.25.1 express@4.17.1 express-jwt@5.3.1 express-jwt-authz@1.0.0 jwks-rsa@1.3.0 npm-run-all@4.1.5 react-router-dom@5.2.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sortMapByValue(map) { | |
| var tupleArray = []; | |
| for (var key in map) tupleArray.push([key, map[key]]); | |
| tupleArray.sort(function (a, b) { | |
| return b[1] - a[1] | |
| }); | |
| var sortedMap = {}; | |
| tupleArray.forEach(function (el) { | |
| sortedMap[el[0]] = el[1] | |
| }); |