A simple Node.js library that formats Brazilian address objects into a Google-style formatted string. It takes an object with fields like street, number, neighborhood, city, state, and postalCode and returns a human-readable address string. Current version 1.3.0, no active development cadence indicated. Differentiates by being focused solely on Brazilian address format with minimal API surface.
npm install br-address-formatterNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to import and use the library to format a Brazilian address object into a string.
Ensure object contains only documented keys: street, number, complement, neighborhood, city, state, postalCode (or zipCode alias).
Do not use for addresses outside Brazil.
Create a .d.ts file: declare module 'br-address-formatter' { function brAddressFormatter(address: Record<string, string>): string; export default brAddressFormatter; }Pass postal code as digits only (e.g., '15085480') and let the library add the hyphen.
Use const brAddressFormatter = require('br-address-formatter'); instead of const { brAddressFormatter } = require('br-address-formatter');Always pass an object (empty if needed): brAddressFormatter({})Use require() or configure a bundler that can handle CommonJS.
No dependency data recorded yet.