I've create a custom Store route inside Shopware 6 as a plugin.
It shows up in the store-api/_info/swagger.html url.
What is does is it return an array with static text for now.
Now is my question, how would i call this url inside the pwa with vuestorefront.
I created a page inside src/pages but i cant wrap my mind around how to call the url to ge the data.
Do i need to specify the whole url in the axios? I cant find any documentation about this.
Thanks in advance!
You approach so far is correct.
src/pages.Now we only need to connect the dots.
Nuxt pages are simply Vue components, so you can use the
invokePostorinvokeGetmethods from theshopware-6-clientpackage to call your custom endpoint.You could also use axios to do it, but then you'll need to handle additional parameters (e.g. passing the correct
sw-context-tokenorsw-access-keymanually.