cm-chess 3.0.0 → 3.0.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cm-chess",
3
- "version": "3.0.0",
3
+ "version": "3.0.1",
4
4
  "description": "It's like chess.js, but in ES6 and can handle variations (tree-structured move history)",
5
5
  "main": "./src/Chess.js",
6
6
  "type": "module",
@@ -25,8 +25,8 @@
25
25
  "homepage": "https://github.com/shaack/cm-chess#readme",
26
26
  "dependencies": {
27
27
  "chess.mjs": "^1.4.0",
28
- "cm-pgn": "3.1.0",
29
- "import-node-module": "^1.0.2"
28
+ "cm-pgn": "3.1.3",
29
+ "node-modules-url": "^1.0.3"
30
30
  },
31
31
  "devDependencies": {
32
32
  "teevi": "^2.2.4"
package/src/Chess.js CHANGED
@@ -3,9 +3,9 @@
3
3
  * Repository: https://github.com/shaack/cm-chess
4
4
  * License: MIT, see file 'LICENSE'
5
5
  */
6
- const {Pgn} = await importNodeModule("/cm-pgn/src/Pgn.js")
7
- const {TAGS} = await importNodeModule("/cm-pgn/src/Header.js")
8
- const {Chess: ChessJs, SQUARES} = await importNodeModule("/chess.mjs/src/Chess.js")
6
+ const {Pgn} = await import(nodeModulesUrl + "cm-pgn/src/Pgn.js")
7
+ const {TAGS} = await import(nodeModulesUrl + "cm-pgn/src/Header.js")
8
+ const {Chess: ChessJs, SQUARES} = await import(nodeModulesUrl + "chess.mjs/src/Chess.js")
9
9
 
10
10
  export const PIECES = {
11
11
  p: {name: "pawn", value: 1},
package/test/TestChess.js CHANGED
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * @author Stefan Haack (https://shaack.com)
3
3
  */
4
- const {TAGS} = await importNodeModule("cm-pgn/src/Header.js")
4
+ const {TAGS} = await import(nodeModulesUrl + "cm-pgn/src/Header.js")
5
5
  import {Chess, COLOR, FEN} from "../src/Chess.js"
6
6
  import {describe, it, assert} from "../node_modules/teevi/src/teevi.js"
7
7
 
package/test/index.html CHANGED
@@ -4,9 +4,9 @@
4
4
  <title>cm-chess tests</title>
5
5
  </head>
6
6
  <body>
7
+ <script type="module" src="../node_modules/node-modules-url/node-modules-url.js"></script>
7
8
  <script type="module">
8
9
  import {teevi} from "../node_modules/teevi/src/teevi.js"
9
- import "../node_modules/import-node-module/import-node-module.js"
10
10
  import "./TestChess.js"
11
11
  import "./TestFen.js"
12
12
  teevi.run()