[英]How can i make back-end for my search-bar in react?
I designed a kind of search bar in react, My question is how can i make a back-end for that to show me the content of the website when i type something to looking for it?我在 React 中设计了一种搜索栏,我的问题是如何制作一个后端,以便在我输入内容进行查找时向我显示网站的内容? Thank you.
谢谢你。
A way could be, making a node-js API backend.一种方法可能是制作一个 node-js API 后端。 Connect that to a database, and then query that database via the API from the react frontend.
将其连接到数据库,然后通过 React 前端的 API 查询该数据库。
A lot of great tutorials online, about setting up nodejs with mongoDb for example.很多很棒的在线教程,例如关于使用 mongoDb 设置 nodejs。 https://medium.com/@sssaini/build-a-restful-api-backend-on-mongodb-using-node-js-and-mongoose-63f0866e4603
https://medium.com/@sssaini/build-a-restful-api-backend-on-mongodb-using-node-js-and-mongoose-63f0866e4603
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.