-
-
Notifications
You must be signed in to change notification settings - Fork 943
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'next' into refactor/locale/normalize-animal-data
- Loading branch information
Showing
10 changed files
with
258 additions
and
104 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
## v9.0 - Tree-Shakeable Module-Functions | ||
|
||
Fix the issue of Faker not being tree shakeable. | ||
Potentially allowing individual Faker methods to be called by themselves. | ||
|
||
[v9.0 Tasks](https://github.com/faker-js/faker/milestone/12) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
### Fix Tree Shaking | ||
|
||
Prior to this version, users had to resort to workarounds by importing specific faker instances from dedicated paths to overcome tree shaking issues. | ||
|
||
```ts | ||
import { faker } from '@faker-js/faker/locale/de'; | ||
``` | ||
|
||
With the implementation of this fix, such workarounds should no longer be necessary. | ||
That means that you should be able to import different localized faker instances from the root of your package. | ||
|
||
```ts | ||
import { fakerDE, fakerES, fakerFR } from '@faker-js/faker'; | ||
``` | ||
|
||
The dedicated import paths will still stay for now, to allow a gradual migration for our users. | ||
|
||
While the implementation of this change does not constitute as breaking according to semantic versioning guidelines, it does impact the behavior of users bundlers. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.