In Wordpress, when programmatically displaying an image through the the_post_thumbnail function, there is a problem with displaying the title tag, by default, when calling the standard function, we will receive only the alt tag. Since this parameter indirectly affects SEO, this problem can be solved in the following ways:
Outputting the title attribute to images:
the_post_thumbnail('name_thumbnail', array( 'title' => get_post(get_post_thumbnail_id())->post_title, ));
Outputting the title attribute to images with the title value of the title of the material:
the_post_thumbnail( 'name_thumbnail', array( 'title' => get_the_title() ) );