1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 09:46:22 +00:00

Merge pull request #1929 from ZeroX-DG/shortcut-mode

Shortcut to toggle mode
This commit is contained in:
Junyoung Choi (Sai)
2018-05-24 14:01:28 +09:00
committed by GitHub
9 changed files with 99 additions and 4 deletions

View File

@@ -54,7 +54,25 @@ export function escapeHtmlCharacters (text) {
: html
}
export function isObjectEqual (a, b) {
const aProps = Object.getOwnPropertyNames(a)
const bProps = Object.getOwnPropertyNames(b)
if (aProps.length !== bProps.length) {
return false
}
for (var i = 0; i < aProps.length; i++) {
const propName = aProps[i]
if (a[propName] !== b[propName]) {
return false
}
}
return true
}
export default {
lastFindInArray,
escapeHtmlCharacters
escapeHtmlCharacters,
isObjectEqual
}