In Magento 1 to display brand or any attribute value. It was easy. We can directly add our code in catalog/product/view.phtml file. But in Magneto 2, It is very strange for us. Because there is no view.phtml file.:(

So You are thinking how to display the value of attribute in product detail page.

Let’s start.

1. Create the brand attribute and add the option of brand

2. Select the brand in product from admin side

3. Create the catalog_product_view.xml file on the path app/design/<Vendor>/<Theme>/Magento_Catalog/layout.

Add this code

4. Now create the brand_info.phtml in the path app/design/<Vendor>/<Theme>/Magento_Catalog/templates/product/view.

Add the code:

5. Now check in product detail page.