Today, HTML has been around for over 20 years. Throughout these two decades, HTML has undergone four upgrades, leading us to the current version, HTML5. However, the upgrade process was not without its challenges. The W3C, the official maintainer of the HTML specification, was slow in introducing new features. As a result, web browser developers took matters into their own hands, leading to compatibility issues and wasted development hours. In today’s technology landscape, HTML5 development is a crucial aspect of front-end development. Despite not being a programming language, HTML5 is an essential component of web and even desktop and mobile applications. Being actively used for 20 years is quite impressive. Consequently, resumes that reference HTML5 experience are now common in the software and web development community. While finding HTML5 experts is relatively easy, finding the perfect candidate remains a challenge.
Our hiring guide aims to help you find HTML5 programmers who prioritize high-quality approaches to enhance user experience and possess extensive knowledge of HTML5 specifications. While there isn’t a foolproof technique, there are certain questions that can help assess a candidate’s depth and proficiency in the language. Here are a few examples:
Questions and Answers
Q: HTML5 was designed to replace both HTML 4 and XHTML. Discuss new HTML5 features and key goals of the HTML5 specification.
Q: Explain what semantic HTML is and name new semantic HTML5 elements.
A: Semantic HTML focuses on using markup that conveys meaning rather than solely focusing on presentation. For instance, HTML5 recommends using the
<strong> tag instead of
<b> for bold text and
<em> instead of
<i> for italic text. These semantic tags not only provide formatting information but also carry meaning.
HTML5 introduced several new semantic elements, such as:
HTML5 also introduced new form controls, including:
Q: Discuss potential pitfalls for developers using HTML5.
A: Developers often fall into the trap of using outdated approaches when writing HTML5 web applications. For example, using the
<table> tag for layout purposes or employing
<div> instead of more appropriate semantic tags like
<aside>. Similarly, failing to use new semantic tags like
<em> instead of
<i> can lead to over-complicated markup that behaves inconsistently across different browsers. To avoid these pitfalls, developers should adopt new semantic tags, leverage the benefits of the HTML5 specification, and leave old habits behind.
Q: Discuss the usage of HTML5 elements in various combinations, such as
A: HTML5 introduced a range of possibilities by allowing different combinations of elements. Contrary to the classic belief that there can only be one
<header> and one
<footer>, an HTML5 document can contain multiple instances of these tags. Each semantic tag is designed to serve its specific purpose within its parent element. Therefore, not only can the
<body> of a page have a header and a footer, but each
<section> element can also have its own header and footer.
Another example involves the usage of
<section> can contain one or multiple
<article> elements, while an
<article> can have multiple
<section> elements. For instance, a web page could feature a dashboard with a
<section> for social network interactions and another
<section> for the latest news articles, with each section containing multiple
<article> elements. Similarly, an
<article> could include a
<section> at the end for reader comments.
Q: Discuss how HTML5 simplified HTML structure. Provide examples.
A: HTML5 introduced several simplifications to the structure of HTML documents. One significant improvement was the simplification of the doctype declaration. In previous versions of HTML, the doctype declaration was more complex and specific to each version. However, HTML5 simplified it by introducing a single, straightforward declaration:
HTML5 also simplified the declaration of character encoding. In contrast to HTML4, which required a meta attribute, HTML5 specifies the charset as
<meta charset="UTF-8">, making it easier to specify the character encoding.
HTML5 went even further in simplification by making the
<head> tags optional. An HTML5 document can be valid without these tags, as demonstrated in the following example:
<p>Wall of text</p>
While these tags are not mandatory, the doctype declaration is essential for the browser to detect the document as HTML5.
Q: Explain why cross-browser support is still important despite modern browsers adhering to the same HTML5 specification.
A: Although modern browsers follow the HTML5 specification, no browser fully supports all the rules defined by the specification. While major browsers generally support most of the features, there are still differences in how each browser interprets HTML5. Therefore, it is important for developers to ensure that the features they use are supported by all the browsers they target. Cross-browser support remains a challenge for developers, despite the improved specifications.
Q: Discuss the accessibility aspects of HTML5, including limitations and real-world problems.
A: As web pages and applications are used more extensively, making them accessible to users reliant on assistive technology is crucial. HTML has come a long way, and HTML5 introduced new user interface features that improve accessibility for those relying on assistive technology. However, there are still challenges to overcome. In the past, developers and designers often neglected accessibility due to the lack of interface features in older web technologies. Even though developers now want to implement additional accessibility options, they face a common problem with emerging web technologies: browser support. HTML5 accessibility keeps track of the most common accessibility features across browsers. Implementing accessibility features and ensuring compatibility with all browsers requires additional time investment from developers. Clients need to be aware of this important factor if they want their web applications and pages to leverage the latest technological possibilities.
Q: Explain HTML5 Web Storage, including security considerations and the difference between localStorage and sessionStorage.
A: HTML5 introduced Web Storage, which enables web pages to store data locally in the user’s browser. Unlike cookies, which were previously used for data storage, Web Storage is more secure and faster. Data stored in Web Storage is not included with every server request, and it remains on the user’s computer until deleted by the web application or the user. Web Storage allows for up to 5MB of storage and is limited to the origin of the page.
While Web Storage is more secure than cookies, certain considerations must be taken into account. It is essential to avoid storing sensitive data like security tokens in Web Storage, as it is not encrypted. Additionally, web applications should not rely solely on data stored in Web Storage, as malicious users can modify the data in localStorage and sessionStorage values at any time.
Speaking of sessionStorage, the main difference between localStorage and sessionStorage lies in their lifetime and scope. Data stored in localStorage is permanent and remains stored until explicitly deleted, while data stored in sessionStorage is tied to the browser tab in which it was created and is deleted when the tab is closed. Unlike localStorage, sessionStorage is window-scoped, meaning scripts running in one tab cannot read or overwrite data written by scripts in another tab, even if both tabs are visiting the same page.
Q: Explain what web workers are.
This guide only scratches the surface of the knowledge required to be a dedicated HTML5 developer. Finding true masters of HTML5 is a challenge. We hope that the questions presented in this post provide a useful foundation for finding the elite few among HTML5 developers. Investing the effort to find such candidates is worthwhile, as they will undoubtedly contribute significantly to your team’s productivity and results.