<?php
$args = [
'posts_per_page' => 10,
'tax_query' => [
[
'taxonomy' => 'post_format',
'field' => 'slug',
'terms' => 'post-format-link'
]
]
];
$recentPosts = new WP_Query( $args );
Code snippets for FacetWP
<?php
$args = [
'posts_per_page' => 10,
'tax_query' => [
[
'taxonomy' => 'post_format',
'field' => 'slug',
'terms' => 'post-format-link'
]
]
];
$recentPosts = new WP_Query( $args );