Added Hint/Solution to "justify-items" Challenge (#20505)

This commit is contained in:
Scott Tran
2018-10-30 21:36:48 -05:00
committed by Ian Duke
parent 360e3fffbd
commit 0275440256

View File

@ -3,8 +3,22 @@ title: Align All Items Horizontally using justify-items
---
## Align All Items Horizontally using justify-items
This is a stub. <a href='https://github.com/freecodecamp/guides/tree/master/src/pages/certifications/responsive-web-design/css-grid/align-all-items-horizontally-using-justify-items/index.md' target='_blank' rel='nofollow'>Help our community expand it</a>.
In this challenge you are required to use the "justify-items" property to horizontally align all the items in the grid.
<a href='https://github.com/freecodecamp/guides/blob/master/README.md' target='_blank' rel='nofollow'>This quick style guide will help ensure your pull request gets accepted</a>.
### Hint
<!-- The article goes here, in GitHub-flavored Markdown. Feel free to add YouTube videos, images, and CodePen/JSBin embeds -->
You can horizontally align the items by declaring the following in your CSS codeblock:
````css
justify-items: value;
````
where value is how you would like to horizontally align the items.
### Solution
Since the challenge requires you to horizontally center all the items, declare the following in your .container CSS codeblock:
````css
justify-items: center;
````