Since the folder structure is not decided yet, I used a folder structure based on the file types. Therefore inside the "src" folder, two folders are created for "pages" and "components".
Root page is added as the basic layout which has the header and the footer. All child routes are rendered using react router inside the root page.
Dummy components are created for Header, Footer and ProductPage.
Using useParams 'productId' is extracted from the URL.
Since the folder structure is not decided yet, I used a folder structure based on the file types. Therefore inside the "src" folder, two folders are created for "pages" and "components".
Root page is added as the basic layout which has the header and the footer. All child routes are rendered using react router inside the root page.
Dummy components are created for Header, Footer and ProductPage.
Using useParams 'productId' is extracted from the URL.