This is my sixth blog about next js
jsx
Import { About, Blog, Contact, House, Program } From "@/Assets/Icons";
Import Styles From "./Navbar.Module.Scss";
Import Image From "Next/Image";
Import Link From "Next/Link";
Const Items = [
{
Title: "Home",
Image: House,
Path: "/",
},
{
Title: "About",
Image: About,
Path: "/About",
},
{
Title: "Technology",
Image: Program,
Path: "/Technology",
},
{
Title: "Blogs",
Image: Blog,
Path: "/Blogs",
},
{
Title: "Contact",
Image: Contact,
Path: "/Contact",
},
];
Export Default Function Navbar() {
Return (
<Div ClassName={Styles.Container}>
<Nav>
<Ul>
{Items.Map((Item) => (
<Li Key={Item.Title}>
<Image Src={Item.Image} Alt={Item.Title} Width={20} Height={20} />
<Link Href={Item.Path}>{Item.Title}</Link>
</Li>
))}
</Ul>
</Nav>
</Div>
);
}
Comments