Skip to content

Localization for NL is not valid for postalCodes #3368

@MDSLKTR

Description

@MDSLKTR

Pre-Checks

Describe the bug

According to the postalCode patterns for the netherlands the following example is allowed in https://github.com/faker-js/faker/blob/v8/src/locales/nl/location/postcode.ts:

1### SS
...
9### SS

same for SA/SD

This is not allowed according to:

https://en.wikipedia.org/wiki/Postal_codes_in_the_Netherlands#:~:text=The%20letter%20combinations%20'SS'%2C,Nazi%20occupation%20of%20the%20Netherlands.&text=The%20first%20two%20digits%20indicate,usually%20on%20the%20same%20street.

Minimal reproduction code

import { fakerNL as faker } from '@faker-js/faker';

console.log(faker.location.zipCode()); // until you hit any of the combos

Additional Context

No response

Environment Info

Faker 8.4.1

Which module system do you use?

  • CJS
  • ESM

Used Package Manager

yarn

Metadata

Metadata

Assignees

No one assigned

    Labels

    c: bugSomething isn't workingm: locationSomething is referring to the location modulep: 1-normalNothing urgents: acceptedAccepted feature / Confirmed bug

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions