chore: Cleanup update banner with localstorage updates (#5209)

Co-authored-by: Aswin Dev P.S <aswindevps@gmail.com>
This commit is contained in:
Pranav Raj S
2022-08-05 13:46:12 +05:30
committed by GitHub
parent fc9699d993
commit 124390a019
5 changed files with 104 additions and 63 deletions

View File

@@ -0,0 +1,8 @@
const semver = require('semver');
export const hasAnUpdateAvailable = (latestVersion, currentVersion) => {
if (!semver.valid(latestVersion)) {
return false;
}
return semver.lt(currentVersion, latestVersion);
};