Merge pull request #109 from SebastienGllmt/patch-1

Add instructions for wordlist removal in webpack
This commit is contained in:
Jonathan Underwood 2019-04-09 18:43:05 +09:00 committed by GitHub
commit d5fb1edc68
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 0 deletions

View File

@ -36,6 +36,16 @@ $ 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
...
plugins: [
new webpack.IgnorePlugin(/^\.\/(?!english)/, /bip39\/src\/wordlists$/),
],
...
```
This is how it will look in the browser console.
```javascript