Let's try here!
https://hens-and-roosters.tk/
I build the local environments using docker-compose ๐ณ.
So you can easily run my app on your machine.
You can start by the following command. And you can see http://localhost:8080/ ๐ป
docker-compose build && docker-compose up frontend
You can run the test by the following command.
docker-compose build && docker-compose up test
Frontend: React
Backend: Express / knex / cloudSQL (postgreSQL)
Backend testing: chai / mock-knex
deployment: Kubernetes (GKE)
Third-party: Bing News Search API / GIPHY / Auth0
See
all blogs as the list.Write
a new blog post with a image and post itEdit
a blogDelete
a blogSee
details of a blogGet
news headline
Endpoint: http://localhost:3000/
Create a blog.
request params
{
"name":"haruna",
"content":"Hello World!!"
}
response (created blog item)
{
"id": 362,
"name": "haruna",
"content": "Hello World!!",
"imageURL": "",
"gifURL": "",
"createdAt": "2020-07-06 05:31:33",
"updatedAt": "2020-07-06 05:31:33"
}
Return blog list.
response (list of blog item)
[{
"id": 362,
"name": "haruna",
"content": "Hello World!!",
"imageURL": "",
"gifURL": "",
"createdAt": "2020-07-06 05:31:33",
"updatedAt": "2020-07-06 05:31:33"
},
{....}
]
Return a blog-item with the given id.
response
{
"id": 362,
"name": "haruna",
"content": "Hello World!!",
"imageURL": "",
"gifURL": "",
"createdAt": "2020-07-06 05:31:33",
"updatedAt": "2020-07-06 05:31:33"
}
Update a blog-item.
request params
{
"content":"Hi, World!!"
}
response (updated blog item)
{
"id": 362,
"name": "haruna",
"content": "Hi, World!!",
"createdAt": "2020-07-06 05:31:33",
"updatedAt": "2020-07-06 05:31:33"
}
Delete a blog-item.
DB name: Hens-and-Roosters
TABLE name: blogs
TABLE schema:
id :int(unique)
name :string
content :text
imageURL: text
gifURL: text
updated_at :Date
updated_at :Date