Thanks for the tutorial it worked as expected until step 3 add Shopify App Bridge. I have copied the code as instructed to test my configuration. When viewing the test app on the "Unhandled Runtime Error AppBridgeError: APP::ERROR::INVALID_CONFIG: shopOrigin must be provided"
this is the server js
I have been reading and studying the text for the last two days. I have not added any custom code. Please provide some guidance.
Solved! Go to the solution
This is an accepted solution.
I had the same problem as I made this tutorial yesterday and in my case in .env the HOST property was missing.
It needs to be set to something like:
Of course changed to your actual ngrok forward url.
Maybe this is also your case.
I cannot see any relation between the HOST property and the shopOrigin cookie.
The reason why you get this error is because in _app.js the config object for the app-bridge-react Provider has undefined value for shopOrigin. In the demo app the value is set from the cookie named shopOrigin. Which, on the other hand, is set on afterAuth by koa-auth-shopify. Check those to track if shopOrigin is set properly.