@postio/address-finder-bundled
v1.0.2
Published
Drop-in UK address autocomplete for any website. Single <script> tag, no build step. Bundled distribution of @postio/address-finder.
Downloads
45
Maintainers
Readme
@postio/address-finder-bundled
Pre-bundled drop-in build of
@postio/address-finder.
Use this when you don't want a build step — drop a <script> tag in,
configure, done.
For bundler-based projects, use @postio/address-finder directly.
For React, use @postio/react.
Use via our CDN (recommended)
<input id="address-search" />
<input id="address-line-1" />
<input id="town" />
<input id="postcode" />
<script src="https://cdn.postio.co.uk/v1/address-finder.js"></script>
<script>
Postio.AddressFinder.setup({
apiKey: "pk_live_…",
input: "#address-search",
output: {
address_line_1: "#address-line-1",
post_town: "#town",
postcode: "#postcode",
},
});
</script>/v1/address-finder.js always points at the latest v1.x.x release.
For exact pinning in production, use the immutable URL — same file,
1-year cache:
<script src="https://cdn.postio.co.uk/v1.0.0/address-finder.js"></script>Use via jsDelivr / unpkg
The same artefact is on npm, so it's auto-mirrored:
<script src="https://cdn.jsdelivr.net/npm/@postio/address-finder-bundled@1"></script>
<script src="https://unpkg.com/@postio/address-finder-bundled@1"></script>Use as a module
<script type="module">
import { setup } from "https://cdn.postio.co.uk/v1/address-finder.esm.js";
setup({ apiKey: "pk_live_…", input: "#search", output: { /* … */ } });
</script>API
Identical to
@postio/address-finder.
License
MIT.
