Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Sorry, but the need to put "<!-- -->" everywhere is a dealbreaker for me.

Example:

  <div class="grid__item  lap--one-half  desk--two-thirds">
      ...
  </div><!--

  --><div class="grid__item  lap--one-half  desk--one-third">
      ...
  </div>
What's the rationale for using inline-block instead of float?


You can actually enable a CSS-only hack[1] to avoid using the comments.

Using `display: inline-block;` allows you to manipulate grids with text-level properties (e.g. `text-align: center;` to cause grid items to fill out from the center of the row), and also allows you to use `vertical-align: [top|middle|bottom];` to cause columns to start from different, well, alignments.

[1] https://github.com/csswizardry/csswizardry-grids/blob/master...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: