- search city by zipcode (Germany only)
- ready to use for autocompletion
- no external dependencies / no ajax calls
- easy to install
- small code size (~160kb) when compressed with gzip
- usable down to IE11
Either download the latest release directly from http://www.das-mensch.de/downloads/zipsearch-1.0.0.js, or clone/download this repo then run npm run build
and finally copy the file zipsearch-1.0.0.js
from the dist directory.
The plugin will register itself under de.dasmensch
. You can access the zip search in the browser as follows
var citiesForZipCodesStartingWith80 = de.dasmensch.searchByZip('80');
// Each city-object has the following structure:
{
cityName: 'München',
zip: '80331',
stateName: 'Bayern'
}