Open maxerbox opened 4 years ago
Hi @maxerbox what is the format of the target_url
?
Have you tried https://www.netlifycms.org/docs/deploy-preview-links/#configuring-preview-paths?
Hi @maxerbox what is the format of the
target_url
? Have you tried https://www.netlifycms.org/docs/deploy-preview-links/#configuring-preview-paths?
My target_url is not pointing on a preview version of the website, but on the building page of my deployment provider. It has this format: https://xxxx.com/maxerbox/sandrine-neau-website/gxb6qir7j the last part is an extract of the commit. I need to transform it to this format : https://sandrine-neau-website-gxb6qir7j.xxxx.app I think a hook is perfect for this case
Updated the title based on the suggestion from https://github.com/netlify/netlify-cms/pull/3966#issuecomment-652856738
The alternative implemented in #3966 would be more extensible. For example, I need to fetch preview URLs from an API based on the GitHub deployment data – that's no possible with the preview_url_formatter: ['regex', 'replacer']
approach.
Is your feature request related to a problem? Please describe. I need to format the preview link given from the target_url statuse api. Indeed, my deploy provider is giving it in the wrong format.
Describe the solution you'd like A simple hook that would allow me to edit the deploy preview url
Describe alternatives you've considered
Additional context Could be done like https://github.com/netlify/netlify-cms/pull/3812