LoginSignup
5
2

More than 1 year has passed since last update.

Next.jsにressを導入する

Posted at

ressとは?

リセットCSSの一つでブラウザがデフォルトで持っているスタイルを打ち消すCSSです。
https://github.com/filipelinhares/ress

パッケージを追加する

yarn add ress

_app.tsxでressを読み込む

import 'ress'を追加してressを読み込む

_app.tsx

import '../styles/globals.scss'
+ import 'ress'

function MyApp({ Component, pageProps }) {
  return <Component {...pageProps} />
}

export default MyApp

完了

手元の環境でリセットCSSが効いているか確認してみてください。

5
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
2