1 | {
|
2 | "name": "chrono-node",
|
3 | "description": "A natural language date parser in Javascript",
|
4 | "homepage": "http://github.com/wanasit/chrono",
|
5 | "repository": {
|
6 | "type": "git",
|
7 | "url": "https://github.com/wanasit/chrono.git"
|
8 | },
|
9 | "prettier": {
|
10 | "quoteProps": "preserve"
|
11 | },
|
12 | "jest": {
|
13 | "verbose": true,
|
14 | "testURL": "http://localhost/",
|
15 | "preset": "ts-jest"
|
16 | },
|
17 | "license": "MIT",
|
18 | "version": "2.7.7",
|
19 | "directories": {
|
20 | "source": "./src",
|
21 | "test": "./test"
|
22 | },
|
23 | "main": "dist/cjs/index.js",
|
24 | "module": "dist/esm/index.js",
|
25 | "exports": {
|
26 | ".": {
|
27 | "require": "./dist/cjs/index.js",
|
28 | "import": "./dist/esm/index.js"
|
29 | },
|
30 | "./*": {
|
31 | "require": "./dist/cjs/locales/*/index.js",
|
32 | "import": "./dist/esm/locales/*/index.js"
|
33 | },
|
34 | "./*/*": {
|
35 | "require": "./dist/cjs/locales/*/*/index.js",
|
36 | "import": "./dist/esm/locales/*/*/index.js"
|
37 | }
|
38 | },
|
39 | "engines": {
|
40 | "node": "^12.20.0 || ^14.13.1 || >=16.0.0"
|
41 | },
|
42 | "sideEffects": false,
|
43 | "types": "dist/esm/index.d.ts",
|
44 | "devDependencies": {
|
45 | "@types/jest": "^26.0.4",
|
46 | "@typescript-eslint/eslint-plugin": "^4.7.0",
|
47 | "@typescript-eslint/parser": "^4.7.0",
|
48 | "benny": "^3.6.15",
|
49 | "eslint": "^7.13.0",
|
50 | "eslint-config-prettier": "^6.15.0",
|
51 | "husky": "^4.2.5",
|
52 | "jest": "^26.1.0",
|
53 | "prettier": "^2.0.5",
|
54 | "rimraf": "^3.0.2",
|
55 | "run-script-os": "^1.1.6",
|
56 | "ts-jest": "^26.1.1",
|
57 | "tsc-esm-fix": "^2.12.4",
|
58 | "typedoc": "^0.20.36",
|
59 | "typescript": "~4.2.4"
|
60 | },
|
61 | "husky": {
|
62 | "hooks": {
|
63 | "pre-commit": "npm run prettier && npm run test:silent"
|
64 | }
|
65 | },
|
66 | "scripts": {
|
67 | "build": "rimraf dist && npm run build-cjs && npm run build-esm && npm run add-package.json",
|
68 | "build-cjs": "tsc -p tsconfig.build.json",
|
69 | "build-esm": "tsc -p tsconfig.build.esm.json && tsc-esm-fix --target=dist/esm",
|
70 | "add-package.json": "run-script-os",
|
71 | "add-package.json:nix": "echo '{\"type\":\"commonjs\",\"sideEffects\":false}' > dist/cjs/package.json && echo '{\"type\":\"module\",\"sideEffects\":false}' > dist/esm/package.json",
|
72 | "add-package.json:windows": "echo {\"type\":\"commonjs\",\"sideEffects\":false} > dist/cjs/package.json && echo {\"type\":\"module\",\"sideEffects\":false} > dist/esm/package.json",
|
73 | "benchmark": "npm run build && node ./benchmark/benchmark.js",
|
74 | "document": "typedoc",
|
75 | "prepare": "npm run build",
|
76 | "eslint": "eslint src test",
|
77 | "prettier": "npm run prettier:src && npm run prettier:test",
|
78 | "prettier:src": "prettier --write src --loglevel=warn",
|
79 | "prettier:test": "prettier --write test --loglevel=warn",
|
80 | "watch": "jest --watch",
|
81 | "test": "jest --coverage",
|
82 | "test:silent": "jest --silent"
|
83 | },
|
84 | "dependencies": {
|
85 | "dayjs": "^1.10.0"
|
86 | },
|
87 | "eslintConfig": {
|
88 | "env": {
|
89 | "es6": true,
|
90 | "node": true,
|
91 | "browser": true
|
92 | },
|
93 | "ignorePatterns": [
|
94 | "benchmark/*.js"
|
95 | ],
|
96 | "parserOptions": {
|
97 | "sourceType": "module",
|
98 | "ecmaFeatures": {
|
99 | "modules": true
|
100 | },
|
101 | "project": "./tsconfig.json"
|
102 | },
|
103 | "parser": "@typescript-eslint/parser",
|
104 | "extends": [
|
105 | "eslint:recommended",
|
106 | "plugin:@typescript-eslint/recommended",
|
107 | "prettier",
|
108 | "prettier/@typescript-eslint"
|
109 | ],
|
110 | "plugins": [
|
111 | "@typescript-eslint"
|
112 | ],
|
113 | "reportUnusedDisableDirectives": true,
|
114 | "rules": {
|
115 | "@typescript-eslint/explicit-module-boundary-types": "off",
|
116 | "@typescript-eslint/no-unused-vars": [
|
117 | "warn",
|
118 | {
|
119 | "args": "none"
|
120 | }
|
121 | ],
|
122 | "prefer-const": "warn"
|
123 | }
|
124 | }
|
125 | }
|