aboutsummaryrefslogtreecommitdiff
path: root/docs/guide
diff options
context:
space:
mode:
authorDivisionByZero <[email protected]>2024-04-15 00:27:11 +0200
committerGitHub <[email protected]>2024-04-15 00:27:11 +0200
commit453ea970a4c7ed19e9d41fd026923f42dbd4e768 (patch)
treeda1e48fa8fc1186b8b185a1f9e24c7d6e921c7cb /docs/guide
parent734a7f3d55d1233d8182585bb79d2013f0ce289e (diff)
downloadfaker-453ea970a4c7ed19e9d41fd026923f42dbd4e768.tar.xz
faker-453ea970a4c7ed19e9d41fd026923f42dbd4e768.zip
refactor(locale)!: remove location data index-value-binding (#2476)
Diffstat (limited to 'docs/guide')
-rw-r--r--docs/guide/upgrading_v9/2476.md12
1 files changed, 12 insertions, 0 deletions
diff --git a/docs/guide/upgrading_v9/2476.md b/docs/guide/upgrading_v9/2476.md
new file mode 100644
index 00000000..b1ee78f8
--- /dev/null
+++ b/docs/guide/upgrading_v9/2476.md
@@ -0,0 +1,12 @@
+### Direction definitions reorganized
+
+The locale definitions used by `faker.location.direction()`, `faker.location.cardinalDirection()` and `faker.location.ordinalDirection()` have been reorganized.
+Previously, they were organized under `definitions.location.direction` and `definitions.location.direction_abbr` and where values were required to be in a specific order.
+Now, all values are nested under `definitions.location.direction` with descriptive property names.
+If you are using the public methods, no changes are required.
+You only need to change your code if you are accessing the raw definitions e.g. in `faker.helpers.fake()`.
+
+| Before | After |
+| ------------------------- | ----------------------------------------------------------------------- |
+| `location.direction` | `location.direction.cardinal` or `location.direction.ordinal` |
+| `location.direction_abbr` | `location.direction.cardinal_abbr` or `location.direction.ordinal_abbr` |