尝试将来自Back4App的产品读取到具有CardItem View React&的网页上Back4App

发布于 2025-01-23 04:32:50 字数 232 浏览 5 评论 0 原文

我目前正在尝试制作一个论坛页面,用户可以将产品发布到论坛页面上供其他用户查看。我将其写入DB并保存产品 - 但是我现在想从产品中读回并生产每种产品供其他用户查看。似乎无法找到太多的指导。 在此处输入图像描述 图像是我创建的ReadProducts函数的当前代码。谢谢

I am currently trying to produce a forum page where users can post products onto a forum page for other users to see. I have it writing to the db and saving the products - however i now want to read back from the products and produce each product for other users to see. Cant seem to find much guidance on it.
enter image description here
Image is current code of the readProducts function that I have created. Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

感情洁癖 2025-01-30 04:32:50
 (async () => {
  // Creates a new Query object to help us fetch MyCustomClass objects
 const query = new Parse.Query('MyCustomClass');
 try {
  // Executes the query, which returns an array of MyCustomClass
  const results = await query.find();
  console.log(`ParseObjects found: ${JSON.stringify(results)}`);
 } catch (error) {
   console.log(`Error: ${JSON.stringify(error)}`);
 }
 })();
 (async () => {
  // Creates a new Query object to help us fetch MyCustomClass objects
 const query = new Parse.Query('MyCustomClass');
 try {
  // Executes the query, which returns an array of MyCustomClass
  const results = await query.find();
  console.log(`ParseObjects found: ${JSON.stringify(results)}`);
 } catch (error) {
   console.log(`Error: ${JSON.stringify(error)}`);
 }
 })();
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文