How to change port for Theme App Extension in Shopify Public App

How to change port for Theme App Extension in Shopify Public App

Faateh
Shopify Partner
17 0 1

I am using node-template for Shopify public app and I installed theme extensions in it. I am trying to run it locally but I get the following error 

theme error.png

 

When I go to this address i get the following error 

theme 2 error.png

I did remove the star_rating.liquid file and added my own file but why is it catching only this file?  I deployed it using yarn deploy command and it deployed successfully but if I start it locally then it gives the above error. Kindly tell me what seems to be the problem. How to change it's port?

Replies 2 (2)

BrainStation23
Shopify Partner
416 62 62

hi @Faateh
You can try passing  the port number by passing a port number using the command line argument port
Try running you're development server using npm run dev -- --port=<PORT>

Brain Station 23 PLC (Mail: js.sbu@brainstation-23.com)
- Was your question answered? Mark it as an Accepted Solution
- Did the solution not address your concern? We kindly request that share or mail your store URL with us this will enable us to collaborate more closely.
- Explore our Shopify public apps

INEEDAMONITOR
Shopify Partner
1 0 0

If you see "The address "http://127.0.0.1:9292" is already in use. Use the --port=PORT option to serve the theme in a different
port." It might because there is another extension is running. You can try this

shopify app dev --theme-app-extension-port <PORT>