admin管理员组文章数量:1122846
const allProducts = useSelect((select) => {
return select('core').getEntityRecords('postType', 'product', {
per_page: -1,
_embed: true,
});
}, [postPerPage, orderBy, order]);
console.log(allProducts);
the out put is :
there is no additional data like product price, onsale etc. how can I fetch the all data of a product?
本文标签: custom post typesI am having a problem with fetching product data in the Gutenberg block editor
版权声明:本文标题:custom post types - I am having a problem with fetching product data in the Gutenberg block editor 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736300146a1930713.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论