The HTML5 menu Tag
As the name suggests, the HTML5 <menu> tag is vital in HTML documents because it is used in defining a list or menu of commands. There are different ways on how it is used. It is important when it comes to putting context menus, toolbars and providing a list of controls and commands.
It is interesting that the <menu> tag is considered as obsolete in HTML4.01. However, the use of it is revived in HTML5.
Even if the HTML5 <menu> tag is compatible with the Global Attributes and Event Attributes in HTML5, this is not recognized by any of the major web browsers that are utilized these days.
When formatting and adding style to the HTML5 <menu> tag, it is necessary to use CSS.
The attributes for the HTML5 <menu> tag are the following:
Attribute |
Value |
Description |
label (New) |
text |
This is used for putting a label for the menu that can be seen by users |
type (New) |
context |
It is the tool in determining the kind of menu that will be displayed. By default, the value is "list" unless altered by the author |