Gatsby
Up and Running with Gatsby: Layouts

Create Header Component

PRO
Outline

In this video, we'll create a header component.

First, create a file called Header.js in /src/components. Then, import React, create a simple function component, and add an h1 tag.

Once that's done, import and use Header in the Layout component.

What if we need to pass some parameters to that component to fine tune which parts of the layout show where? We'll learn about that in the next video.

 

I finished! On to the next chapter