Responsive Grid Systems Comparison
The purpose of the test is to find out how semantic grid systems perform against presentational grid systems.
Definitions
Semantic grids allow complete separation of mark-up and presentation (e.g. "sidebar" can be any column width in any viewport). With semantic grid systems, the mark-up will not be polluted with presentational classes.
Presentational grids are based on presentational classes (e.g. "phone-2-12 tablet-4-12" means the div will be 2 columns out of 12 columns width in phone viewport and 4 column out of 12 column width in tablet viewport)
Combination grids are grid systems that can be used in both manners.
Check this link for more information on presentational versus semantic classes.
Test description
- 12 column fluid grid
- two breakpoints (mobile and min-width 768px).
- Various column widths and combinations
- With the exception of class names, the html structure stays the same.
The CSS specific to the grid was separated in its own file (css/grid.css) to measure the results of the test more accurately.
All the tested grid systems contain only grid styles (with the exception of Skeleton which is more of a bootstrap).
Presentational | Semantic | Combination | |||||||
---|---|---|---|---|---|---|---|---|---|
Criteria | CSSSmartGrid | DeadSimpleGrid | ResponsiveGridSystem | SimpleGrid | Skeleton | Neat | ProfoundGrid | CSSWizardryGrids | Griddle |
Max Columns | 121 | N/A | 12 | 12 | 12 | 121 | 121 | 12 | 12 |
Library file size | 25K | 250 bytes | 45K | 4K | 11K | 35K | 6K | 20K | 4KB |
Preprocessor Dependencies |
SASS, Bourbon |
NONE | NONE | NONE | NONE | SASS, Bourbon |
SASS | SASS | SASS |
Support | All, IE8+ | All, IE9+ IE8 with Respond.js |
All, IE8+ | All, IE8+ | All, IE9+ | All, IE9+ IE8 with selectivizr |
All, IE8+ | All, IE8+ | All, IE8+ |
Documentation5 | Sparse | Sparse | Rich | Sparse | Abundant | Abundant | Sparse | Rich | Unmaintained |
Source | Source | Source | Source | Source | Source | Source | Source | Source | Source |
Official Demo | Demo | Demo | Demo | Demo | Demo | Demo | Demo | Demo | Demo |
Customization capabilities and features out of the box | |||||||||
Gutter Types | Fluid Fixed None |
None | Fluid 1.6% | Fixed 20px | Fluid 4% | Fluid Fixed None |
Fluid Fixed None |
Fixed Fluid None |
Fixed Fluid None |
Concurent Multiple Gutter Types |
No | No | No | No | No | Yes | No | No | No |
# of Breakpoints | 1 only | None | 1 only | 1 only | 1 only | As needed | As needed | As needed | As needed |
Class Names | Customizable | Customizable3 | Fixed | Fixed | Fixed | Customizable | Customizable | Customizable | Both |
Offsets (push/pull) |
Yes | No | No | Yes | Yes | Yes | Yes | Yes | No |
Column Number | Yes | Yes4 | No | No | No | Yes | Yes | No | Yes |
Generated CSS file size | 3k | 3k | 8k | 4k | 3k | 2k | 54k | Presentational: 26k Semantic: 10k2 |
Presentational: 5k Semantic: 5k |
HTML file size | 5k | 5k | 5k | 4k | 5k | 5k | 5k | Presentational: 6k Semantic: 5k |
Presentational: 7k Semantic: 7k |
Test Page | Presentational | Presentational | Presentational | Presentational | Presentational | Semantic | Semantic | Presentational Semantic |
Presentational Semantic |
Notes | Technically you could make a semantic grid system, but realistically no. | You might as well build your own custom grid system. | Requires a lot of work to customize the grid and the gutters. | It's one of the best grid systems that doesn't use a preprocessor. | Skeleton is a framework, so the dev has to remove non-grid styles. | It offers the most options one can think of. The learning curve might be a little steeper because there are so many features. A less experienced developer can easily misuse it. | It's too finicky and it doesn't support columns of unequal width in the same row. | You can't customize the number of columns. If you need to indend the first column, then you need to indend all the columns in hat row. | Semantic means that you can add divs of fixed widths within a grid and the rest of the divs will occupy the remaining space in a fluid fashion. |
Technically unlimited number of columns, with the specified number being the default columns number provided by the library.
There are a lot of comments which ad to the overall css file size.
Technically you can name the classes anyway you want because the Dead Simple Grid system doesn't provide any class names except for parent "grid".
Technically unlimited number of columns because Dead Simple Grid system doesn't provide a number of columns.
- Unmaintained (inexistent or outdated documentation; abandoned project),
- Sparse (very few sources of documentation or official documentation is meagre),
- Rich (everything you need in one place, usually the project's official Documentation),
- Abundant (many documentation sources).
Conclusions
- There is no perfect grid system. It all depends on the project and a variety of factors. See "Key questions to choose a grid system" below.
- Semantic grid doesn't necessarily mean less generated CSS.
- There are significantly more presentational grids than semantic.
- The best grid system is Neat. A close runner up is CSSwizardry.
- The best presentational grid system is CSS Smart Grid.
- If the project is small and simple, it's ok to go with a presentational grid system.
- All semantic grid systems have the potential to generate presentational css, whereas presentational grid systems can never be semantic.
Key questions to choose a grid system
- How large is the project?
- Does the grid need customization?
- Do you need fixed or fluid gutters?
- Do you need multiple types of gutter grids or gutterless grids?
- Do you need just the grids or a whole bootstrap?
- What preprocessor do you use?
- How seasoned are the developers with grid systems? What about preprocessors?
- What browsers are you going to support?