> For the complete documentation index, see [llms.txt](https://haeuns-organization.gitbook.io/megaptera-frontend-course/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://haeuns-organization.gitbook.io/megaptera-frontend-course/week8/2.style-basic.md).

# 2. Style Basic

## CSS 설정 : class

```js
<style>
  .greeting {
    color: #00F;
  }
</style>
```

## CSS 설정 : inline style

css를 자바스크립트 객체로 만들어서 전달

```js
export default function Greeting() {
  const style = {
    color: '#00F',
  };

  return (
    <p style={style}>
      Hello, world!
    </p>W
  );
}
```

```js
export default function Greeting() {
  return (
    <p
      style={{
        color: '#00F',
      }}
    >
      Hello, world!
    </p>
  );
}
```
