// Once the template loads set focus to the h1 to manage focus if(previous.$$route){ history = previous.$$route.originalPath; } // if there is no history this is the first page the user sees on the app if (history) { var h1 = document.querySelector('h1'); if (h1) { h1.setAttribute('tabindex', '-1'); h1.focus(); } } } });
set automatically based on other properties, for example aria-checked may be obtained from checked. aria-checked aria-valuemin aria-valuemax aria-valuenow aria-invalid aria-required aria-readonly aria-disabled aria-pressed aria-selected aria-label aria-hidden