Home App Docs Blog Github

Why does builder.getAll not return all results?

You may notice that builder.getAll() doesn’t always return all of your content.

This is because, by default, Builder.io applies targeting rules - so if you are for instance trying to do builder.getAll('page') you may get no results, or just the pages that match the current URL

To change this behavior and fetch everything, use the noTargeting option:

// This will return all pages, regardless of current url
builder.getAll('page', { options: { noTargeting: true }})
1 Like