Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
398 views
in Technique[技术] by (71.8m points)

html - Why this class "font-weight-bold" doesn't work? [Bootstrap]

  <head>
    <meta charset="utf-8">
    <link rel="stylesheet" href="/css/bootstrap.css">
  </head>
  <body>

    <h1 class="h1">Bootstrap</h1>
    <p class="font-weight-bold">Palabra</p>
    <p class="font-italic">Palabra</p>

  </body>
</html>

Adding "font-weight-bold" class to a p doesn't make any change to the text

No change

What can i do?

question from:https://stackoverflow.com/questions/65848992/why-this-class-font-weight-bold-doesnt-work-bootstrap

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

It's font-weight-bold for bootstrap 4

And class="fw-bold" for Bootstrap 5


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...