STEP-2 - Create Magento 2 Frontend Route and Basic Controller
At [MODULE]/etc folder create frontend folder and routes.xml file in it
app/code/ScandiPWA/Version/etc/frontend/routes.xml
2. At [MODULE] create /Controller/Version folders and Index.php in the Version folder
app/code/ScandiPWA/Version/Controller/Version/Index.php
4. Run and set:up
and c:f
, switch to Luma theme, if you will navigate to http://localhost/scandipwa/version you should see the output, however, if you will switch back to ScandiPWA theme you going to see 404 Page.
Useful Materials Magento 2 Creating a New Page
PreviousSTEP-1 Creating Magento 2 ModuleNextSTEP-3 Accessing Magento 2 Controller, Bypassing ScandiPWA frontend
Last updated