Skip to content

Commit bed6241

Browse files
committedNov 14, 2020
Fix CI
1 parent fa3db76 commit bed6241

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed
 

‎.gitignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ node_modules/
22
js/data.json
33
package-lock.json
44
data.json
5-
dist
65
coverage
76
test.js
87
bench.js
8+
mod.d.ts
9+
mod.js

‎bench.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* eslint-disable @typescript-eslint/no-var-requires */
22
/* eslint-disable no-console */
33
const Benchmark = require("benchmark");
4-
import { distance } from "./dist";
4+
import { distance } from "./mod.js";
55
import { get as fastLevenshtein } from "fast-levenshtein";
66
const fs = require("fs");
77
const jslevenshtein = require("js-levenshtein");

‎package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
"name": "fastest-levenshtein",
33
"version": "1.0.12",
44
"description": "Fastest Levenshtein distance implementation in JS.",
5-
"main": "dist/index.js",
6-
"types": "dist/index.d.ts",
5+
"main": "mod.js",
6+
"types": "mod.d.ts",
77
"repository": {
88
"type": "git",
99
"url": "git+https://github.com/ka-weihe/fastest-levenshtein.git"
@@ -34,7 +34,7 @@
3434
},
3535
"homepage": "https://github.com/ka-weihe/fastest-levenshtein#README",
3636
"scripts": {
37-
"build": "rm -rf dist && tsc && for i in dist/mod.*; do mv $i \"${i/mod/index}\"; done",
37+
"build": "tsc mod.ts --declaration",
3838
"prepare": "npm run build",
3939
"bench": "npm run build && tsc bench.ts && node bench.js",
4040
"test": "npm run build && tsc test.ts && jest test.js",

‎test.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { closest, distance } from "./dist";
1+
import { closest, distance } from "./mod.js";
22

33
const levenshtein = (a, b) => {
44
if (a.length === 0) {

‎tsconfig.json

-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
"module": "commonjs",
55
"declaration": true,
66
"declarationMap": true,
7-
"outDir": "./dist",
87
"strict": true,
98
"esModuleInterop": true,
109
"skipLibCheck": true,

0 commit comments

Comments
 (0)
Please sign in to comment.