Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

pgn-parser

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pgn-parser - npm Package Compare versions

Comparing version
2.0.0
to
2.1.0
+8
-8
package.json
{
"name": "pgn-parser",
"version": "2.0.0",
"version": "2.1.0",
"description": "pgn parser",

@@ -22,3 +22,3 @@ "keywords": [

"test": "mocha",
"dist": "webpack -p"
"dist": "NODE_ENV=production webpack"
},

@@ -28,11 +28,11 @@ "main": "dist/pgn-parser.js",

"devDependencies": {
"pegjs": "^0.10.0",
"chai": "^4.2.0",
"clean-webpack-plugin": "^3.0.0",
"mocha": "^7.1.1",
"raw-loader": "^4.0.1",
"terser-webpack-plugin": "^3.0.1",
"webpack": "^4.43.0",
"webpack-cli": "^3.3.11"
"mocha": "^8.2.1",
"pegjs": "^0.10.0",
"raw-loader": "^4.0.2",
"terser-webpack-plugin": "^5.0.3",
"webpack": "^5.11.1",
"webpack-cli": "^4.3.0"
}
}

@@ -97,3 +97,18 @@ const chai = require('chai'),

});
it('should allow move after RAV without whitespace', () => {
const [result] = parser.parse('1. e4 (1. d4 d5)e5 2. d4 exd4 *');
result.moves.should.have.lengthOf(4);
});
it('should allow RAV after RAV without whitespace', () => {
const [result] = parser.parse('1. e4 (1. d4 d5)(1. f4 e5)e5 2. d4 exd4 *');
result.moves.should.have.lengthOf(4);
});
it('should allow promotion without equal sign', () => {
const [result] = parser.parse('1. e4 f5 2. exf5 g6 3. fxg6 h6 4. g7 Rh7 5. gxf8Q+ *');
result.moves.should.have.lengthOf(9);
});
it('should allow multiple RAV for same move', () => {

@@ -159,2 +174,8 @@ const [result] = parser.parse('1. e4 (1. d4 d5) (1. c4 e5) e5 *');

});
it('should parse accented characters', () => {
const results = parser.parse('1.e4 {A à E é I î O ô U ù Y} *');
results[0].moves[0].comments.should.have.lengthOf(1);
results[0].moves[0].comments[0].text.should.be.eql('A à E é I î O ô U ù Y');
});
});

@@ -40,5 +40,6 @@ const path = require('path'),

new TerserWebpackPlugin({
cache: true,
parallel: true,
sourceMap: true
terserOptions: {
sourceMap: true
}
})

@@ -45,0 +46,0 @@ ]

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet