<dir> tag in HTML
The <dir> tag is used to defines a directory list. The <dir> element very similar to <ul> element.
Important Description
- The <dir> tag is not supported in HTML5.
- Use <ul> tag on the behalf of <dir> tag in HTML5.
- Open and close tag required of <dir>.
Example of <dir> tag
Result Look Like
Apple
Banana
Mango
<dir> Tag Browser Support
Element |
Chrome |
Edge |
Firefox |
Safari |
Opera |
<dir> |
Yes |
Yes |
Yes |
Yes |
Yes |
Global Attributes
Event Attributes
Attributes
Attribute |
Value |
Description |
compact |
campact |
Specifies that the list should display smaller than normal. (Not supported in HTML5) |