【发布时间】:2022-08-22 20:44:20
【问题描述】:
因此,当我使用 Router.push 时,我发送的查询将被覆盖
Router.push({
pathname: `/product/${subCategoryValue}`,
query: { category: helpWith, industry: industry },
});
当我在/product/${subCategoryValue} 页面上console.log(query) 时,唯一出现的是url 参数(子类别值)。
-
subCategoryValue不是查询参数吗?例如:?categoryId=1 -
但是当我 console.log(query) 它出现在那里
-
你能告诉我们
/product/${subCategoryValue}页面的代码吗?
标签: next.js