git clone https://github.com/drlncode/Motivational-Phrases
cd Motivational-Phrases
npm install or pnpm install
npm run dev
- After that, enter to: http://localhost:3000.
- The API is a very simple API-JSON that only consists of one endpoint, which is:
https://motivational-phrases-demo.vercel.app/phrases
- To make a request to the API and then consume it, do the following:
const URL = 'https://https://motivational-phrases-demo.vercel.app/phrases';
fetch(URL)
.then(response => response.json())
.then(json => {
// Whatever you're going to do to consume it.
})
.catch(err => console.error);
- Feel free to make any contribution to the project, whether it's adding a feature to the project or adding phrases to the json in
app/data/phrases.json
. Everything is welcome.