1.3.0 • Published 3 years ago
@howtocodewell/header-menu v1.3.0
How To Code Well header-menu
The header menu of How To Code Well which is shared across multiple sites
Install
$ npm install --save @howtocodewell/header-menu$ npm run buildUsage
1) Create the following config file in <project_root>/src/config/headerMenu.json and change name and url values.
{
"items": [
{
"name": "Overriden",
"url": "https://howtocodewell.net/merch"
},
{
"name": "Courses",
"url": "https://howtocodewell.net/shop"
},
{
"name": "Tutorials",
"url": "https://howtocodewell.net/courses"
},
{
"name": "Orders",
"url": "https://codechallenges.howtocodewell.net"
}
]
}2) Import the module and config
import HeaderMenu from "@howtocodewell/header-menu"
import menu from "./config/headerMenu.json"3) Load the HeaderMenu and pass the menu property
<HeaderMenu menu={menu} />