LoginSignup
1
0

More than 1 year has passed since last update.

Next.jsで画像を配置する方法

Last updated at Posted at 2022-01-08

Next.jsで画像を配置する方法

最近学んだことをoutputするために書きました。

やり方

①まずpublicフォルダにstatic fileを作り、その中に画像をぶち込みます。
②その次に画像を配置したいフォルダー内に行き、Imageタグで画像を表示していきます。この時、publicは"/"で表示できるので気をつけましょう。

<Image 
src="/static/logo.png"
alt="logo"
width="150px"
height="50px"
/>

以上で表示できます!以上グッピーでした!

参考にした記事

1
0
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
1
0