Questions and discussions about using the Shopify CLI and Shopify-built libraries.
Using the CLI command shopify theme dev command, I'm unable to log into a customer account to be able to preview/modify those templates. My guess is there's some kind of authentication/cookie issue since it's at http://127.0.0.1:9292/ but this is a significant road block for using the CLI for development. Has anyone run into this and found a fix? I want to be able to edit shopify code that utilizes user accounts. Thanks!
Solved! Go to the solution
This is an accepted solution.
Hi again Mike - I've tried this out on my side too and am seeing the same behaviour. I believe this was possible previously, and will connect with the CLI team today to flag this with them. Will update here soon!
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
This is an accepted solution.
Hi again Mike,
So it's possible to view the customer pages in local dev by disabling the captcha settings at Online Store > Preferences. Then restart your dev server, and you'll be able to log into customer pages on the locally running instance:
Hope this helps!
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
This is an accepted solution.
Hi Mike,
Correct - you would disable captcha for the connected store (in the store admin settings). If you don't want to have captcha disabled on a live store, you could set up a development store just for developing your theme (including customer pages), where the captcha protection would be disabled. When you want to populate changes across to the live store (where the captcha protection would still be enabled) you could use the Shopify GitHub Integration and push your changes to a connected GitHub repo.
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
Hi Mike - which version of the CLI are you using?
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
The absolute newest one.
Current Shopify CLI version: 3.46.5
This is an accepted solution.
Hi again Mike - I've tried this out on my side too and am seeing the same behaviour. I believe this was possible previously, and will connect with the CLI team today to flag this with them. Will update here soon!
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
This is an accepted solution.
Hi again Mike,
So it's possible to view the customer pages in local dev by disabling the captcha settings at Online Store > Preferences. Then restart your dev server, and you'll be able to log into customer pages on the locally running instance:
Hope this helps!
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
Do I have to disable captcha for my live store, or is this somewhere else? Thanks for the clarification and your help in the matter.
This is an accepted solution.
Hi Mike,
Correct - you would disable captcha for the connected store (in the store admin settings). If you don't want to have captcha disabled on a live store, you could set up a development store just for developing your theme (including customer pages), where the captcha protection would be disabled. When you want to populate changes across to the live store (where the captcha protection would still be enabled) you could use the Shopify GitHub Integration and push your changes to a connected GitHub repo.
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
Okay, this is what we are actually planning to do, we're just waiting for Shopify to tell us our store is finished cloning. Thanks for your help.
A simple solution would be to use the preview link generated on the console when you run shopify theme dev and login there. The development work might slow down a bit since you need to refresh the page manually when you make changes, but that's it.