-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpackage.json
More file actions
106 lines (106 loc) · 3.09 KB
/
package.json
File metadata and controls
106 lines (106 loc) · 3.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
{
"name": "detect-translation",
"version": "0.3.1",
"description": "Trigger code when people translate your website",
"keywords": [
"translation",
"detect",
"detector",
"language",
"baidu fanyi",
"bing translate",
"google translate",
"microsoft translator",
"yandex translate",
"naver papago"
],
"main": "dist/index.cjs",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"exports": {
".": {
"browser": {
"import": {
"types": "./dist/index.d.cts",
"default": "./dist-browser/index.min.js"
},
"require": {
"types": "./dist/index.d.ts",
"default": "./dist-browser/index.min.js"
},
"default": "./dist-browser/index.min.js"
},
"import": {
"types": "./dist/index.d.mts",
"default": "./dist/index.mjs"
},
"require": {
"types": "./dist/index.d.ts",
"default": "./dist/index.cjs"
}
}
},
"browser": "dist-browser/index.min.js",
"unpkg": "dist-browser/index.min.js",
"jsdelivr": "dist-browser/index.min.js",
"author": "Claudiu Ceia",
"license": "MIT",
"type": "commonjs",
"packageManager": "pnpm@10.22.0",
"files": [
"dist",
"dist-browser"
],
"scripts": {
"build": "rimraf dist dist-browser && tsup && node -e \"require('fs').copyFileSync('dist/index.d.ts','dist/index.d.cts')\" && pnpm run build:browser",
"build:browser": "esbuild src/index.ts --bundle --format=iife --global-name=DetectTranslation --minify --sourcemap --outfile=dist-browser/index.min.js",
"lint": "biome check .",
"format": "biome format --write .",
"test": "pnpm run langids && jest",
"e2e:only": "playwright test --project=chromium",
"e2e:all": "playwright test",
"e2e": "pnpm run build && pnpm run e2e:only",
"typecheck": "tsc -p tsconfig.json --noEmit",
"typecheck:e2e": "tsc -p tsconfig.e2e.json --noEmit",
"knip": "knip",
"security:audit": "pnpm audit --audit-level high",
"prepublish": "pnpm test && pnpm run lint && pnpm run typecheck && pnpm run typecheck:e2e && pnpm run knip && pnpm run build && pnpm run package-check && pnpm run security:audit",
"prepare": "husky",
"langids": "tsx ./.bin/writeLangIds.ts",
"package-check": "publint"
},
"repository": {
"type": "git",
"url": "git+ssh://git@github.com/ClaudiuCeia/detect-translation.git"
},
"pnpm": {
"onlyBuiltDependencies": [
"@swc/core",
"esbuild",
"unrs-resolver"
]
},
"devDependencies": {
"@biomejs/biome": "^2.3.14",
"@playwright/test": "^1.58.2",
"@swc/core": "^1.15.11",
"@swc/jest": "^0.2.39",
"@types/jest": "^30.0.0",
"@types/node": "^25.2.2",
"@types/sanitize-html": "^2.16.0",
"cldr": "^8.0.0",
"esbuild": "^0.27.3",
"husky": "^9.1.7",
"jest": "^30.2.0",
"jest-environment-jsdom": "^30.2.0",
"js-yaml": "^4.1.1",
"jsdom": "^28.0.0",
"knip": "^5.83.1",
"publint": "^0.3.17",
"rimraf": "^6.1.2",
"sanitize-html": "^2.17.0",
"tsup": "^8.5.1",
"tsx": "^4.21.0",
"typescript": "^5.9.3"
}
}