Closed as not planned
Closed as not planned
Description
Description
When using a query loop block on a vanilla WP with Gutenberg plugin activated (on v17.1.3), the query loop often returns empty. If you dig into the REST API calls in your browser, you can see that the offset
value is actually being passed the per_page
+ offset
, so instead of offset=0&per_page=12
, you end up with offset=120&per_page=12
Step-by-step reproduction instructions
- Launch a new WP install
- Install Gutenberg v17.1.3
- Add the query loop or modify the main page template (you'll need to disable the 'inherit query from template' setting)
- Mess with any of the pagination settings, per page, offset, etc. Then watch the network tab for the /posts/ endpoint.
Screenshots, screen recording, code snippet

Environment info
- WP 6.4.1
- Gutenberg 17.1.3
- Any theme (I used TT4)
- Tested in PHP 8.0 and 8.1
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes