Skip to content

Commit

Permalink
Add instructions for webpack
Browse files Browse the repository at this point in the history
Sharing this for anybody else that needs it 👍
  • Loading branch information
SebastienGllmt authored Apr 7, 2019
1 parent cd6bcdb commit 5cf326c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@ $ browserify -r bip39 -s bip39 \
```

This will create a bundle that only contains the chinese_simplified wordlist, and it will be the default wordlist for all calls without explicit wordlists.

You can also do this in Webpack using the `IgnorePlugin`. Here is an example of excluding all non-English wordlists

```javascript
new webpack.IgnorePlugin(/^\.\/(?!english)/, /bip39\/src\/wordlists$/),
```

This is how it will look in the browser console.

Expand Down

0 comments on commit 5cf326c

Please sign in to comment.