@scrabble-solver/word-lists 2.9.1 → 2.9.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2021 Kamil Mielnik <kamil.adam.mielnik@gmail.com>
1
+ Copyright (c) 2022 Kamil Mielnik <kamil@kamilmielnik.com>
2
2
 
3
3
  Attribution-NonCommercial-NoDerivatives 4.0 International
4
4
 
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const lib_1 = require("./lib");
4
- const FILE_URL = 'https://raw.githubusercontent.com/enz/german-wordlist/master/words';
4
+ const FILE_URL = 'https://raw.githubusercontent.com/hippler/german-wordlist/master/words.txt';
5
5
  const getDeDeWordList = async () => {
6
6
  return (0, lib_1.getTxtWordList)(FILE_URL);
7
7
  };
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- const cheerio_1 = __importDefault(require("cheerio"));
6
+ const cheerio_1 = require("cheerio");
7
7
  const memfs_1 = require("memfs");
8
8
  const unzipper_1 = __importDefault(require("unzipper"));
9
9
  const url_1 = require("url");
@@ -28,7 +28,7 @@ const fetchZipUrl = async (url) => {
28
28
  return href;
29
29
  };
30
30
  const parseZipContainingPage = (html) => {
31
- const $ = cheerio_1.default.load(html);
31
+ const $ = (0, cheerio_1.load)(html);
32
32
  const $links = $('a');
33
33
  const links = Array.from($links)
34
34
  .map((link) => $(link).attr('href'))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scrabble-solver/word-lists",
3
- "version": "2.9.1",
3
+ "version": "2.9.3",
4
4
  "description": "Scrabble Solver 2 - Word lists",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -10,8 +10,8 @@
10
10
  },
11
11
  "author": {
12
12
  "name": "Kamil Mielnik",
13
- "email": "kamil.adam.mielnik@gmail.com",
14
- "url": "https://kamilmielnik.com/"
13
+ "email": "kamil@kamilmielnik.com",
14
+ "url": "https://kamilmielnik.com"
15
15
  },
16
16
  "license": "CC-BY-NC-ND-4.0",
17
17
  "bugs": {
@@ -24,7 +24,7 @@
24
24
  "clean:force": "npm run clean && rimraf package-lock.json"
25
25
  },
26
26
  "dependencies": {
27
- "@scrabble-solver/types": "^2.9.1",
27
+ "@scrabble-solver/types": "^2.9.3",
28
28
  "cheerio": "^1.0.0-rc.12",
29
29
  "follow-redirects": "^1.15.2",
30
30
  "memfs": "^3.4.7",
@@ -34,5 +34,5 @@
34
34
  "@types/follow-redirects": "^1.14.1",
35
35
  "@types/unzipper": "^0.10.5"
36
36
  },
37
- "gitHead": "4849b4d123131fe043174f000c523868f3bd68c5"
37
+ "gitHead": "ef8d030cbb76256a377f747f7ebe4b85b7eba61e"
38
38
  }
@@ -1,6 +1,6 @@
1
1
  import { getTxtWordList } from './lib';
2
2
 
3
- const FILE_URL = 'https://raw.githubusercontent.com/enz/german-wordlist/master/words';
3
+ const FILE_URL = 'https://raw.githubusercontent.com/hippler/german-wordlist/master/words.txt';
4
4
 
5
5
  const getDeDeWordList = async (): Promise<string[]> => {
6
6
  return getTxtWordList(FILE_URL);
@@ -1,4 +1,4 @@
1
- import cheerio from 'cheerio';
1
+ import { load } from 'cheerio';
2
2
  import { fs } from 'memfs';
3
3
  import unzipper from 'unzipper';
4
4
  import { URL } from 'url';
@@ -28,7 +28,7 @@ const fetchZipUrl = async (url: string): Promise<string> => {
28
28
  };
29
29
 
30
30
  const parseZipContainingPage = (html: string): string => {
31
- const $ = cheerio.load(html);
31
+ const $ = load(html);
32
32
  const $links = $('a');
33
33
  const links = Array.from($links)
34
34
  .map((link) => $(link).attr('href'))