frend / frend.co

Frend — A collection of accessible, modern front-end components.
http://frend.co
MIT License
635 stars 25 forks source link

Bypass links - avoid null target error #84

Closed adamduncan closed 8 years ago

adamduncan commented 8 years ago

If a bypass link has been included in the page, but its target (id) isn't present in page, throws null errors.

Make sure we're testing for the presence of target before we try to set/removeAttribute or focus it, etc.

Might be a good chance to update e.target to e.currentTarget, as per #76.