Fixing HTML and CSS order

- Changing paragraph content.
pull/6213/head
BabakFP 5 years ago committed by GitHub
parent 18195ee4a5
commit 160add5634
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -5,6 +5,8 @@ title: Styling
Just like in HTML, you can add a `<style>` tag to your component. Let's add some styles to the `<p>` element:
```html
<p>Hello, Svelte!</p>
<style>
p {
color: purple;
@ -12,8 +14,6 @@ Just like in HTML, you can add a `<style>` tag to your component. Let's add some
font-size: 2em;
}
</style>
<p>This is a paragraph.</p>
```
Importantly, these rules are *scoped to the component*. You won't accidentally change the style of `<p>` elements elsewhere in your app, as we'll see in the next step.
Importantly, these rules are *scoped to the component*. You won't accidentally change the style of `<p>` elements elsewhere in your app, as we'll see in the next step.

Loading…
Cancel
Save