addressit is a JavaScript library designed to parse freeform street address text into a structured object. The current stable version is 1.8.2. Recent releases have primarily focused on maintenance and minor feature additions, indicating an irregular but active release cadence. Its primary differentiator is its specialized focus on extracting the street parsing components (unit, building number, street name, and street type). Broader geographical details like city, state, or country are collected into a generic `regions` array, requiring further application-specific processing. This design choice acknowledges the vast variability of global address formats and avoids attempting a universal, country-specific identification within the core library. It is best suited for applications where extracting the fundamental street information from unstructured text is paramount, rather than providing comprehensive geopolitical address validation.
npm install addressitVerified import paths — ran on the pinned version, not inferred.
Demonstrates parsing a street address string and logging the structured output.
Ensure that Node.js v16 or a newer version is used for both development and production environments when working with `addressit` v1.8.1 or later.
Implement custom logic or integrate with external geographical data services to further process the `regions` array if detailed city, state, or country identification is required.
Run `npm install addressit` or `yarn add addressit` in your project directory to install the dependency.
Ensure you are using `const addressit = require('addressit');` for CommonJS or `import addressit from 'addressit';` for ESM setups.Always pass a valid string as the first argument to the `addressit()` function, ensuring it's not null or undefined.
No dependency data recorded yet.