Supporting domain with path
Closed this issue · 3 comments
I currently work on a Vue3 project that is deployed in three separated environments.
The way we handled those environments is by having a specific path to each other: https://<our-domain>.twic.pics/<our-env-path>
The problem is that when I try to feed the vue configuration with app.use(TwicPics, { domain: 'https://<our-domain>.twic.pics/<our-env-path>'})
, I got this error:
Uncaught (in promise) Error: twicpics-components install domain "https://<our-domain>.twic.pics/<our-env-path>" is invalid
Hello @YannDuv and thank you for using TwicPics Components
.
Your use case is indeed not supported.
In the current version, the configuration template expects for domain
a value as configured on your TwicPics
account. eg: https://<our-domain>.twic.pics
.
That said, we find your idea of using paths at configuration time interesting.
The configuration of your requirement would become
app.use(TwicPics, { domain: 'https://<our-domain>.twic.pics', path:'<our-env-path>' })
We are working on it right now.
Hello @YannDuv .
Version 0.6.5 should allow you to configure the path in the installation phase (https://github.com/TwicPics/components/blob/main/documentation/vue3.md#setup-options).
To resume your example, you can now use
app.use(TwicPics, { domain: 'https://<our-domain>.twic.pics', path:'<our-env-path>' })
Hope this helps.
Thank you ✨