Link the text Docs to /docs.
Acceptance criteria
- 1.Link the text Docs to /docs.
HTML Tutorial · HTML Tags
These 10 tasks go with the HTML <a> Tag chapter. 5 of them ask you to build something small from scratch; 5 give you code that is already broken and ask you to work out why. Set aside about 90 minutes for the whole set, though you can do them in any order.
Nothing here is marked by a person. When you press Submit, the editor checks your code against the points listed under each task and tells you straight away what passed and what didn't (you need a free account to submit). If you get stuck, there are hints, and a worked solution once you've had a go. The first 2 tasks are free; the rest are part of the practice plan.
If it's been a while since you read the chapter, here is how it starts: “The tag, also known as the anchor tag , is used to create hyperlinks in HTML. It allows users to navigate between web pages , jump to specific sections , download files , or even send emails using mailto: links. It is one of the most important elements for web navigation and interconnectivity.” .
1.Link to a pageexercise · easy · 10 min
Link the text Docs to /docs.
Passes when: Link the text Docs to /docs.
2.Open in a new tabexercise · easy · 10 min · practice plan
Make the link open in a new tab.
Passes when: Make the link open in a new tab.
3.Link to an emailexercise · easy · 10 min · practice plan
Link to an email address.
Passes when: Link to an email address.
4.Jump to a sectionexercise · easy · 10 min · practice plan
Link to the section with id contact.
Passes when: Link to the section with id contact.
5.A safe external linkexercise · medium · 10 min · practice plan
Add an external link that opens safely in a new tab.
Passes when: Add an external link that opens safely in a new tab.
6.Fix the missing hrefbug fix · easy · 8 min
An anchor without href is not a link.
Passes when: An anchor without href is not a link.
7.Fix the wrong attribute for the targetbug fix · easy · 8 min · practice plan
New tabs use target, not new.
Passes when: New tabs use target, not new.
8.Fix the email link missing its schemebug fix · easy · 8 min · practice plan
Email links need the mailto: scheme.
Passes when: Email links need the mailto: scheme.
9.Fix the anchor with no target sectionbug fix · easy · 8 min · practice plan
The jump link points at an id that does not exist.
Passes when: The jump link points at an id that does not exist.
10.Fix the unsafe new-tab linkbug fix · easy · 8 min · practice plan
A link opening a new tab should set rel for safety.
Passes when: A link opening a new tab should set rel for safety.
Between them these tasks cover Anchors, href and target and rel.
Looking for a different chapter? See every practice set, or switch to the interview theory questions.