javascript - How to remove initial auto focus of anchor tag -


i wondering how remove automatic focus automatically happens first anchor tag on page load.

i not looking disable focus ability pretty able find solutions while researching question. focus should still apply , show when anchor clicked.

here css (scss in case) focus itself, want remain.

&:focus {      outline:3px solid #51ace9 } 

i have tried doing rid of auto focus on page load:

window.onload= function() {   var anchors = document.getelementsbyclassname('my_class')   (var = 0; < anchors.length; i++) {     anchors[i].blur();   } } 

but doesn't seem work.

can suggest proper solution?

$(document).ready(function({    $("a").blur() ;      }); 

Comments

Popular posts from this blog

ruby - Trying to change last to "x"s to 23 -

jquery - Clone last and append item to closest class -

c - Unrecognised emulation mode: elf_i386 on MinGW32 -