Skip to content

Instantly share code, notes, and snippets.

@outoftime
Last active October 23, 2017 22:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save outoftime/816ed09493011fab38c811ecb1fd1991 to your computer and use it in GitHub Desktop.
Save outoftime/816ed09493011fab38c811ecb1fd1991 to your computer and use it in GitHub Desktop.
Exported from Popcode. Click to import: https://popcode.org/?gist=816ed09493011fab38c811ecb1fd1991

Imagine you are creating a website to showcase the awards of your favorite celebrity.

Create a website that includes:

  • A title that takes up 100% of the page width
  • At least 2 columns for the content (you choose the width and content)

Example

Tips

  • Start by identifying the parent element that will be the flex box.
  • What CSS properties do you use to set the parent element's display to be a flexbox?
  • What CSS property do you use to make the child elements appear on the page as columns?
  • How do you define how wide an element is on the page?

If you finish early…

You’re only getting started with Flexbox! If you finish early, look up the following properties of flexbox and see if you can use it in your page.

Parent element:

  • align-items
  • align-content
  • flex-grow
  • flex-shrink

Child elements:

  • order
  • align-self
<!DOCTYPE html>
<html>
<head>
<title>My Favorite Celebrity</title>
</head>
<body>
</body>
</html>
{"hiddenUIComponents":["editor.javascript"]}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment