Contents
HTML menuitem: Main Tips
- HTML
<menuitem>
tag was used to declare a command which the user could request from a popup menu. - To set up a new command, you could utilize one or multiple of tag-specific attributes.
- You could also use the
command
attribute to connect to other commands. - HTML
menuitem
tag has been deprecated since HTML 5.2.
What <menuitem> Meant
Now unsupported HTML menuitem
element defined a command to invoke from the popup menu by the user:
Example
<img src="https://cdn.bitdegree.org/learn/pom-laptop.png?raw=true" id="doggo" width="250" alt="Space Doggo" contextmenu="sunmenu">
<menu type="context" id="sunmenu">
<menuitem label="Zoom In" icon="https://github.com/bitdegree/banners/blob/master/banners/html_small.png?raw=true" onclick="zoomin()">
<menuitem label="Zoom Out" icon="https://github.com/bitdegree/banners/blob/master/banners/html_small.png?raw=true" onclick="zoomout()">
<menuseparator/>
<menuitem label="Reload Image" icon="https://github.com/bitdegree/banners/blob/master/banners/html_small.png?raw=true" onclick="window.location.reload();">
</menu>
In the example above, you can also see a <menuseparator/>
tag which created a HTML menuitem
separator. It was a thin line separating the possible commands. When creating a website, HTML menuitem
separator could be used to group similar options to simplify the user experience.

Pros Main Features
- Easy to use with a learn-by-doing approach
- Offers quality content
- Gamified in-browser coding experience
- The price matches the quality
- Suitable for learners ranging from beginner to advanced
- Free certificates of completion
- Focused on data science skills
- Flexible learning timetable

Pros Main Features
- Simplistic design (no unnecessary information)
- High-quality courses (even the free ones)
- Variety of features
- Nanodegree programs
- Suitable for enterprises
- Paid Certificates of completion

Pros Main Features
- A wide range of learning programs
- University-level courses
- Easy to navigate
- Verified certificates
- Free learning track available
- University-level courses
- Suitable for enterprises
- Verified certificates of completion
Tag Attributes Used With HTML menuitem
There were seven tag-specific attributes to the now unsupported HTML menuitem
. See them in the table below:
Attribute | Description |
---|---|
radiogroup | Defined the name of a group of commands to toggle. |
checked | Identified the element as checked when the page was loading. |
default | Set a command as the default one for menuitem. |
disabled | Disabled the menuitem. |
icon | Defined an icon for a specific menuitem. |
label | Defined the menuitem's name to show to the user. |
command | Indicated the ID of an individual element, pointing to a command to be requested indirectly. |
type | Defined the menuitem type (command by default). |
Browser support

Chrome
-

Edge
-

Firefox
8+

IE
-

Opera
-

Safari
-
Mobile browser support

Chrome
-

Firefox
8+

Opera
-

Safari
-