How to filter WP attachments

By default, FacetWP only indexes published items, which excludes attachments. To index attachments (media items) too, use this hook:

add_filter( 'facetwp_indexer_query_args', function( $args ) {
    $args['post_status'] = array( 'publish', 'inherit' );
    return $args;
});

Make sure to re-index afterwards.