Merge Objects prototype extensions

This commit is contained in:
djmaze 2020-09-04 17:07:35 +02:00
parent 0647b5201f
commit f2d194947d
26 changed files with 108 additions and 127 deletions

View file

@ -44,7 +44,7 @@ export class AbstractScreen {
fMatcher = null;
const routes = this.routes();
if (Array.isArray(routes) && routes.length) {
if (Array.isNotEmpty(routes)) {
fMatcher = (this.onRoute || (()=>{})).bind(this);
route = new Crossroads();

View file

@ -12,7 +12,7 @@ let currentScreen = null,
const SCREENS = {},
qs = s => document.querySelector(s),
isNonEmptyArray = values => Array.isArray(values) && values.length,
isNonEmptyArray = Array.isNotEmpty,
autofocus = dom => {
// if (!bMobileDevice) {
const af = dom.querySelector('[autofocus]');