mirror of
https://github.com/Sped0n/bridget.git
synced 2026-04-21 21:49:31 -07:00
refactor(state.ts): extract logic to get threshold session index into a separate function for reusability and clarity
This commit is contained in:
@@ -14,9 +14,19 @@ initNav()
|
||||
if (ijs.length > 0) {
|
||||
if (!isMobile()) {
|
||||
import('./desktop/init')
|
||||
.then((d) => d.initDesktop(ijs))
|
||||
.catch((e) => console.log(e))
|
||||
.then((d) => {
|
||||
d.initDesktop(ijs)
|
||||
})
|
||||
.catch((e) => {
|
||||
console.log(e)
|
||||
})
|
||||
} else {
|
||||
import('./mobile/init').then((m) => m.initMobile(ijs)).catch((e) => console.log(e))
|
||||
import('./mobile/init')
|
||||
.then((m) => {
|
||||
m.initMobile(ijs)
|
||||
})
|
||||
.catch((e) => {
|
||||
console.log(e)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user