improved <b> tag article (#23496)
Expanded b tag article to provide greater clarity and additional guidance Replaced example with more appropriate one Removed link to w3schools as info there is out of date and therefore misleading
This commit is contained in:
committed by
mrugesh mohapatra
parent
030e673e6a
commit
cbc6909b0d
@ -4,17 +4,21 @@ title: B Tag
|
|||||||
|
|
||||||
## B Tag
|
## B Tag
|
||||||
|
|
||||||
The `<b>` tag is used to specify bold text, without conveying any special importance or relevance. When bolding text of special importance or relevance, it is recommended that you use the `<strong>` tag.
|
Formerly used to bold text the `<b>` tag is now known as the 'Bring Attention To element' tag. It should be used only to draw attention to the contents of the element.
|
||||||
|
|
||||||
|
Most browsers will display text in bold type but you should not use it for this purpose, instead use CSS `font-weight` property for purely visual display reasons. If you wish to signify the elements content are of special importance use the `<strong>` tag instead.
|
||||||
|
|
||||||
|
An appropriate use case is drawing attention to keywords in a text.
|
||||||
|
|
||||||
### Example:
|
### Example:
|
||||||
```html
|
```html
|
||||||
<b>This text is bold</b>
|
Examples of extinct <b>fauna</b>include ...
|
||||||
```
|
```
|
||||||
This would appear as:
|
This would appear as:
|
||||||
|
|
||||||
**This text is bold**
|
Examples of extinct **fauna** include ...
|
||||||
|
|
||||||
#### More Information:
|
#### More Information:
|
||||||
<!-- Please add any articles you think might be helpful to read before writing the article -->
|
<!-- Please add any articles you think might be helpful to read before writing the article -->
|
||||||
1. [w3schools](https://www.w3schools.com/tags/tag_b.asp "<b> Tag: w3schools") <br />
|
|
||||||
2. [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/b)
|
1. [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/b)
|
||||||
|
Reference in New Issue
Block a user