50
loading...
This website collects cookies to deliver better user experience
To solidify my Frontend Skills so that I can be just done with the chaotic CSS stuff and be confident in that so that I could now focus on the Backend stuff which is very interesting.
And Hashnode's home feed was the perfect thing to do as it was really responsive and had really good & complex components too.
I love its UI as a product and also because I don't think anyone had cloned it before.
import express from "express";
import axios from "axios";
export const getBlogsData = async (req, res) => {
const app = express();
try {
var body = {
operation: "search_by_hash",
schema: "blogs",
table: "data",
hash_values: [1, 2, 3, 4, 5, 6],
get_attributes: ["*"],
};
var config = {
method: "post",
url: process.env.HARPERDB_URL,
headers: {
"Content-Type": "application/json",
Authorization: process.env.AUTHORIZATION,
},
data: body,
};
const resData = await axios(config);
res.send(resData.data);
} catch (e) {
console.log("Could not get data : " + e);
}
};