Custom Routes
Clone this repository:
git clone https://github.com/traveloka/soya-next.git
cd soya-next/examples/custom-routes
Then, install and run it:
npm install
npm start
To use it, create a configuration file at
config/default.json
with the following:{
"routes": {
"/path/:param1/:param2": {
"page": "/path/to/custom-page"
}
}
}
Last modified 4yr ago