Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML

m-t-3 or m-b-3 It should be mt-3 and mb-3

Is this old Bootstrap4 course.? Thanks

Bill

1 Answer

Hi,

It should be mt-3 or mb-3. The pattern is: {property}{sides}-{size}.

Where property is:

  • m (for classes that set margin)
  • p (for classes that set padding)

Where sides:

  • t (for classes that set margin-top or padding-top)
  • b (for classes that set margin-bottom or padding-bottom)
  • l (for classes that set margin-left or padding-left)
  • r (for classes that set margin-right or padding-right)
  • x (for classes that set both *-left and *-right)
  • y (for classes that set both *-top and *-bottom)
  • a (for classes that set a margin or padding on all 4 sides of the element)

Where size is one of:

  • 0 for classes that eliminate the margin or padding by setting it to 0
  • 1 (by default) for classes that set the margin or padding to $spacer-x or $spacer-y
  • 2 (by default) for classes that set the margin or padding to $spacer-x * 1.5 or $spacer-y * 1.5
  • 3 (by default) for classes that set the margin or padding to $spacer-x * 3 or $spacer-y * 3

You can find more information utilities/spacing section in the bootstrap4 documentation

Bootstrap4 still in development, so there are things that might change.

I hope it helps. Have a nice day