Skip to content

Small update #189

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 5 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<p align="center">
<div align="center">
<img src="./assets/img/bulb.svg" width="200" alt="light bulb icon">
</p>
</div>

# CSS Protips [![Awesome](https://cdn.rawgit.com/sindresorhus/awesome/d7305f38d29fed78fa85652e3a63e154dd8e8829/media/badge.svg)](https://github.com/sindresorhus/awesome)

Expand Down Expand Up @@ -51,7 +51,7 @@ A collection of tips to help take your CSS skills pro.

### Use a CSS Reset

CSS resets help enforce style consistency across different browsers with a clean slate for styling elements. You can use a CSS reset library like [Normalize](http://necolas.github.io/normalize.css/), _et al._, or you can use a more simplified reset approach:
CSS resets help enforce style consistency across different browsers with a clean slate for styling elements. There are plenty of reset patterns to find, or you can use a more simplified reset approach:

```css
*,
Expand Down Expand Up @@ -230,12 +230,12 @@ No, it's not black magic, you really can center elements vertically. You can do
html,
body {
height: 100%;
margin: 0;
}

body {
align-items: center;
display: flex;
justify-content: center;
}
```

Expand All @@ -245,8 +245,7 @@ body {
body {
display: grid;
height: 100vh;
margin: 0;
place-items: center center;
place-items: center;
}
```

Expand All @@ -270,7 +269,6 @@ img {
}
```


Learn more about the `aspect-ratio` property in this [web.dev post](https://web.dev/articles/aspect-ratio).

#### [Demo](https://codepen.io/AllThingsSmitty/pen/MWxwoNx/)
Expand Down