Skip to content

Commit

Permalink
improvements to address normalizer
Browse files Browse the repository at this point in the history
  • Loading branch information
cdepage committed Apr 28, 2024
1 parent e9e723a commit e72c43b
Show file tree
Hide file tree
Showing 10 changed files with 3,433 additions and 176 deletions.
7 changes: 4 additions & 3 deletions docs/address/normalize.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,13 @@ addressNormalize: (value: string) => string;
## How to Use

```javascript
addressNormalize('1234 Main st sw apt14-a');
addressNormalize('1234 Main Street S.West apt # 14-a');
addressNormalize('1234 Main Street south-west apt 14-a');
// "1234 MAIN STREET SW APT 14-A"
addressNormalize('1234 Main Street south-west, apt 14-a');
// "1234 MAIN ST SW APT 14-A"

addressNormalize('apartment 3c, south-east cloverfield ave, manville nj 08835');
addressNormalize('apmt 3c se cloverfield ave manville nj 08835');
addressNormalize('apmt 3c se cloverfield avenue manville nj 08835');
// "APT 3C SE CLOVERFIELD AVE MANVILLE NJ 08835"

addressNormalize('p.o.b 1234');
Expand Down
2 changes: 1 addition & 1 deletion packages/address/normalize/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const { addressNormalize } = require('@zerodep/address-normalize');
```javascript
addressNormalize('1234 Main Street S.West apt # 14-a');
addressNormalize('1234 Main Street south-west apt 14-a');
// "1234 MAIN STREET SW APT 14-A"
// "1234 MAIN ST SW APT 14-A"

addressNormalize('apartment 3c, southeast cloverfield ave, manville nj 08835');
addressNormalize('apmt 3c se cloverfield ave manville nj 08835');
Expand Down
2 changes: 1 addition & 1 deletion packages/address/normalize/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@zerodep/address-normalize",
"description": "A utility that normalizes an address string for ease of parsing",
"version": "2.4.5",
"version": "2.4.6",
"license": "MIT",
"repository": {
"type": "git",
Expand Down

0 comments on commit e72c43b

Please sign in to comment.