Skip to content

Commit

Permalink
feat: Migrate to typescript (#6)
Browse files Browse the repository at this point in the history
BREAKING CHANGE: migration to typescript
  • Loading branch information
josoriom authored Dec 12, 2022
1 parent 247abfb commit 5f43507
Show file tree
Hide file tree
Showing 7 changed files with 96 additions and 102 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,6 @@ jspm_packages
lib
lib-esm

docs
docs

dist
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,18 +39,18 @@
"devDependencies": {
"@babel/plugin-transform-modules-commonjs": "^7.19.6",
"@babel/preset-typescript": "^7.18.6",
"@types/jest": "^29.2.3",
"@types/jest": "^29.2.4",
"codecov": "^3.8.2",
"eslint": "^8.28.0",
"eslint": "^8.29.0",
"eslint-config-cheminfo-typescript": "^11.2.2",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-jest": "^27.1.5",
"eslint-plugin-jest": "^27.1.6",
"eslint-plugin-no-only-tests": "^3.1.0",
"eslint-plugin-prettier": "^4.2.1",
"jest": "^29.3.1",
"npm-run-all": "^4.1.5",
"prettier": "^2.7.1",
"prettier": "^2.8.1",
"rimraf": "^3.0.2",
"typescript": "^4.9.3"
"typescript": "^4.9.4"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ describe('fromLabels', () => {
it('should sort labels alphabetically', () => {
const CM = ConfusionMatrix.fromLabels([1, 3, 2], [1, 1, 1], {
sort: (a, b) => {
return a - b;
return (a as number) - (b as number);
},
});
expect(CM.getLabels()).toStrictEqual([1, 2, 3]);
Expand Down
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit 5f43507

Please sign in to comment.