Created
May 12, 2022 20:54
-
-
Save lobot/3f1da2cf51000e8efa839810a5c20656 to your computer and use it in GitHub Desktop.
international AC
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script setup> | |
import AddressAutocomplete from '@lob/vue-address-autocomplete' | |
import '@lob/vue-address-autocomplete/dist/styles.css' | |
</script> | |
<template> | |
<main> | |
<label for="country" style="margin-right: 1em">Country</label> | |
<select name="country" id="country" v-model="countryCode" style="margin-bottom: 1em"> | |
<option value="MX">Mexico</option> | |
<option value="CA">Canada</option> | |
<option value="FR">France</option> | |
<option value="CN">China</option> | |
</select> | |
<AddressAutocomplete | |
apiKey="YOUR_API_KEY_HERE" | |
isInternational=true | |
:country="countryCode" | |
/> | |
</main> | |
</template> | |
<script> | |
export default { | |
data() { | |
return { | |
countryCode: "" | |
} | |
} | |
} | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment