<script lang="ts">
const {t} = useI18n();
const route = useRoute();
const query = route.query;
const buttonUrl = computed(() => {
// Get the base URL from translations
const baseUrl = t('cta.button.url');
// Convert the route query parameters to a query string
const queryString = new URLSearchParams(query).toString();
// Return the full URL, appending the query string if it exists
return queryString ? `${baseUrl}?${queryString}` : baseUrl;
});
</script>
<script lang="ts">
const {t} = useI18n();
const route = useRoute();
const query = route.query;
const buttonUrl = computed(() => {
// Get the base URL from translations
const baseUrl = t('cta.button.url');
// Convert the route query parameters to a query string
const queryString = new URLSearchParams(query).toString();
// Return the full URL, appending the query string if it exists
return queryString ? `${baseUrl}?${queryString}` : baseUrl;
});
</script>