Skip to main content
9 events
when toggle format what by license comment
Nov 18, 2022 at 16:02 vote accept zero-samurai
Nov 17, 2022 at 15:25 answer added kero timeline score: 1
Nov 17, 2022 at 15:09 history edited Tom J Nowell CC BY-SA 4.0
added 10 characters in body
Nov 17, 2022 at 15:08 comment added Tom J Nowell @kero please post your answer as an answer, not a comment
Nov 17, 2022 at 15:07 comment added Tom J Nowell Unrelated to your error, you've tried to use per_page: -1 which is not possible, and if it were possible would be dangerous. The REST API caps requests at 100 posts for performance and scaling reasons. Arguably you should also be doing this in server side queries but there is no cap there, so while you can try to use -1, you will never get all posts unless there are less than 100. The API returns 10 per page by default
Nov 17, 2022 at 15:04 comment added zero-samurai @kero That absolutely fixed it! Thank you very much!
Nov 17, 2022 at 14:40 comment added kero The error reads "Rendered more hooks than during the previous render." - so I'd assume the useBlockProps() is the culprit here. If you move that above the conditional return, does it work again?
S Nov 17, 2022 at 14:24 review First questions
Nov 18, 2022 at 16:10
S Nov 17, 2022 at 14:24 history asked zero-samurai CC BY-SA 4.0