How to add "SKIP TO MAIN CONTENT" to websites
Why and how to add "skip to main content" to a page for web accessibility

I am a Front end developer currently working on React JS, HTML, CSS, Python, Vue JS, Webpack, Babel, AEM etc.
Search for a command to run...
Why and how to add "skip to main content" to a page for web accessibility

I am a Front end developer currently working on React JS, HTML, CSS, Python, Vue JS, Webpack, Babel, AEM etc.
No comments yet. Be the first to comment.
Are you planning to start your coding journey?. Then this is for you - a roadmap to help you achieve your goals.

7 ways in which you can add files to your commit using git add

As a website user, one would have come across links or buttons which say "Click to download" or "Download" on a website. Have you ever wondered how can you add one to your website?. Keep reading!!!. As part of this blog let us see how one can crea...

Display Hello World and custom message using two-way data binding

Build a random quote generator using an API - JavaScript

Kritika Pattalam Bharathkumar | Web Developer - The official blog of Kritika Pattalam Bharathkumar
22 posts
Front End Engineer | Writes about HTML, CSS, JavaScript and everything related to web development | Follow me on Twitter let's chat.
As part of this blog post let's see what is web accessibility, and how to add "skip to main content" link for web pages and why?.
As per w3.org
Web accessibility means that websites, tools, and technologies are designed and developed so that people with disabilities can use them. More specifically, people can: perceive, understand, navigate, and interact with the Web contribute to the Web
For a normal user when he visits a page, he/she directly jumps to the section of the page where they want to read. But if we consider visually impaired users or someone who uses screen reader, the assistive device has to read through the entire page before they can reach a point which interests them.
Let's assume when a user lands on the page , the screen reader will read the entire navigation/header and then goes to the actual content of the page. The user reads through the first page of your website once, now he/she goes to the second page and the screen reader will again start reading the entire navigation for them before they can go to the main content. This is where "SKIP TO MAIN CONTENT" link comes in handy for them.
<body>
<a class="skip-link" href="#main-content">SKIP TO MAIN CONTENT</a>
<header> .....</header>
<main id="main-content">
Main Body Content .....
</main>
<footer>......</footer>
</body>
.skip-link {
position: absolute;
left: -999px;
width: 1px;
height: 1px;
top: auto;
}
.skip-link:active, .skip-link:focus {
color: #000;
display: inline-block;
height: auto;
width: auto;
position: static;
margin: auto
}
Please share your feedbacks and suggestions in the comments below.
Lets connect on Twitter | LinkedIn for more web development related chats.