html-validate 6.7.0 → 6.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "html-validate",
3
- "version": "6.7.0",
3
+ "version": "6.9.0",
4
4
  "description": "Offline html5 validator",
5
5
  "keywords": [
6
6
  "html",
@@ -54,6 +54,94 @@
54
54
  "workspaces": [
55
55
  "tests/integration/*"
56
56
  ],
57
+ "scripts": {
58
+ "prebuild": "run-s codegen prebuild:*",
59
+ "build": "run-s build:*",
60
+ "postbuild": "bash scripts/pkg",
61
+ "prebuild:tsc": "tsc --build src",
62
+ "build:cjs": "rollup --config rollup.cjs.config.js",
63
+ "build:dts": "rollup --config rollup.dts.config.js",
64
+ "build:esm": "rollup --config rollup.esm.config.js",
65
+ "clean": "rm -rf dist public",
66
+ "codegen": "node scripts/codegen",
67
+ "compatibility": "scripts/compatibility.sh",
68
+ "debug": "node --inspect ./node_modules/.bin/jest --runInBand --watch --no-coverage",
69
+ "docs": "grunt docs",
70
+ "eslint": "eslint .",
71
+ "eslint:fix": "eslint --fix .",
72
+ "htmlvalidate": "node ./bin/html-validate.js",
73
+ "prepack": "npm run build && release-prepack package.json",
74
+ "postpack": "release-postpack package.json",
75
+ "prepare": "husky install && npm run codegen",
76
+ "prettier:check": "prettier --check .",
77
+ "prettier:write": "prettier --write .",
78
+ "start": "grunt connect",
79
+ "test": "jest --ci",
80
+ "version": "scripts/version"
81
+ },
82
+ "commitlint": {
83
+ "extends": "@html-validate",
84
+ "rules": {
85
+ "scope-enum": [
86
+ 2,
87
+ "always",
88
+ [
89
+ "api",
90
+ "cli",
91
+ "config",
92
+ "context",
93
+ "deps",
94
+ "dom",
95
+ "elements",
96
+ "engine",
97
+ "error",
98
+ "eslint",
99
+ "event",
100
+ "formatters",
101
+ "html5",
102
+ "htmlvalidate",
103
+ "jest",
104
+ "lexer",
105
+ "meta",
106
+ "parser",
107
+ "plugin",
108
+ "prettier",
109
+ "release",
110
+ "reporter",
111
+ "rules",
112
+ "schema",
113
+ "transform",
114
+ "utils"
115
+ ]
116
+ ]
117
+ }
118
+ },
119
+ "lint-staged": {
120
+ "*.{ts,js,json,html,md,scss,yml}": "prettier --write"
121
+ },
122
+ "prettier": "@html-validate/prettier-config",
123
+ "release": {
124
+ "extends": "@html-validate/semantic-release-config"
125
+ },
126
+ "jest": {
127
+ "collectCoverageFrom": [
128
+ "src/**/*.ts",
129
+ "!src/**/*.spec.ts",
130
+ "!src/**/index.ts",
131
+ "!src/index.ts",
132
+ "!src/browser.ts",
133
+ "!src/cli/html-validate.ts",
134
+ "!src/jest/jest.ts",
135
+ "!**/__fixtures__/**"
136
+ ],
137
+ "preset": "@html-validate/jest-config",
138
+ "roots": [
139
+ "<rootDir>/docs",
140
+ "<rootDir>/elements",
141
+ "<rootDir>/src",
142
+ "<rootDir>/tests"
143
+ ]
144
+ },
57
145
  "dependencies": {
58
146
  "@babel/code-frame": "^7.10.0",
59
147
  "@html-validate/stylish": "^2.0.0",
@@ -62,16 +150,81 @@
62
150
  "ajv": "^8.0.0",
63
151
  "deepmerge": "^4.2.0",
64
152
  "espree": "^9.0.0",
65
- "glob": "^7.1.0",
153
+ "glob": "^8.0.0",
66
154
  "ignore": "^5.0.0",
67
155
  "kleur": "^4.1.0",
68
156
  "minimist": "^1.2.0",
69
157
  "prompts": "^2.0.0",
70
158
  "semver": "^7.0.0"
71
159
  },
160
+ "devDependencies": {
161
+ "@babel/core": "7.17.9",
162
+ "@babel/preset-env": "7.16.11",
163
+ "@html-validate/commitlint-config": "2.1.9",
164
+ "@html-validate/eslint-config": "5.4.4",
165
+ "@html-validate/eslint-config-jest": "5.4.4",
166
+ "@html-validate/eslint-config-typescript": "5.4.0",
167
+ "@html-validate/eslint-config-typescript-typeinfo": "5.4.1",
168
+ "@html-validate/jest-config": "3.0.2",
169
+ "@html-validate/prettier-config": "2.1.0",
170
+ "@html-validate/release-scripts": "3.4.0",
171
+ "@lodder/grunt-postcss": "3.1.1",
172
+ "@rollup/plugin-json": "4.1.0",
173
+ "@rollup/plugin-replace": "4.0.0",
174
+ "@rollup/plugin-typescript": "8.3.2",
175
+ "@rollup/plugin-virtual": "2.1.0",
176
+ "@types/babar": "0.2.1",
177
+ "@types/babel__code-frame": "7.0.3",
178
+ "@types/estree": "0.0.51",
179
+ "@types/glob": "7.2.0",
180
+ "@types/jest": "27.4.1",
181
+ "@types/minimist": "1.2.2",
182
+ "@types/node": "12.20.49",
183
+ "@types/prompts": "2.0.14",
184
+ "@types/semver": "7.3.9",
185
+ "autoprefixer": "10.4.5",
186
+ "babar": "0.2.2",
187
+ "babelify": "10.0.0",
188
+ "bootstrap-sass": "3.4.3",
189
+ "canonical-path": "1.0.0",
190
+ "cssnano": "5.1.7",
191
+ "dgeni": "0.4.14",
192
+ "dgeni-front-matter": "3.0.0",
193
+ "dgeni-packages": "0.29.3",
194
+ "font-awesome": "4.7.0",
195
+ "front-matter": "4.0.2",
196
+ "grunt": "1.5.2",
197
+ "grunt-browserify": "6.0.0",
198
+ "grunt-cli": "1.4.3",
199
+ "grunt-contrib-connect": "3.0.0",
200
+ "grunt-contrib-copy": "1.0.0",
201
+ "grunt-sass": "3.1.0",
202
+ "highlight.js": "11.5.1",
203
+ "husky": "7.0.4",
204
+ "jest": "27.5.1",
205
+ "jest-diff": "27.5.1",
206
+ "jest-snapshot": "27.5.1",
207
+ "jquery": "3.6.0",
208
+ "lint-staged": "12.4.0",
209
+ "load-grunt-tasks": "5.1.0",
210
+ "marked": "2.1.3",
211
+ "npm-pkg-lint": "1.10.0",
212
+ "npm-run-all": "4.1.5",
213
+ "postcss": "8.4.12",
214
+ "prettier": "2.6.2",
215
+ "rollup": "2.70.2",
216
+ "rollup-plugin-copy": "3.4.0",
217
+ "rollup-plugin-dts": "4.2.1",
218
+ "sass": "1.50.1",
219
+ "serve-static": "1.15.0",
220
+ "stringmap": "0.2.2",
221
+ "ts-jest": "27.1.4",
222
+ "typescript": "4.6.3"
223
+ },
72
224
  "peerDependencies": {
73
- "jest": "^24 || ^25 || ^26 || ^27",
74
- "jest-diff": "^24 || ^25 || ^26 || ^27"
225
+ "jest": "^25.1 || ^26 || ^27",
226
+ "jest-diff": "^25.1 || ^26 || ^27",
227
+ "jest-snapshot": "^25.1 || ^26 || ^27"
75
228
  },
76
229
  "peerDependenciesMeta": {
77
230
  "jest": {
@@ -79,9 +232,17 @@
79
232
  },
80
233
  "jest-diff": {
81
234
  "optional": true
235
+ },
236
+ "jest-snapshot": {
237
+ "optional": true
82
238
  }
83
239
  },
84
240
  "engines": {
85
241
  "node": ">= 12.22"
242
+ },
243
+ "renovate": {
244
+ "extends": [
245
+ "gitlab>html-validate/renovate-config"
246
+ ]
86
247
  }
87
248
  }
@@ -1,36 +0,0 @@
1
- import { o as Message, a as ConfigData, a9 as TokenType, L as Location } from './core.js';
2
-
3
- interface TokenMatcher {
4
- type: TokenType;
5
- location?: Partial<Location>;
6
- data?: any;
7
- }
8
- declare global {
9
- namespace jest {
10
- interface Matchers<R, T = {}> {
11
- toBeValid(): R;
12
- toBeInvalid(): R;
13
- toBeToken(expected: TokenMatcher): R;
14
- toHaveError(error: Partial<Message>): R;
15
- toHaveError(ruleId: string, message: string, context?: any): R;
16
- toHaveErrors(errors: Array<[string, string] | Record<string, unknown>>): R;
17
- /**
18
- * Validate string or HTMLElement.
19
- *
20
- * Test passes if result is valid.
21
- *
22
- * @param config - Optional HTML-Validate configuration object.
23
- * @param filename - Optional filename used when matching transformer and
24
- * loading configuration.
25
- */
26
- toHTMLValidate(): R;
27
- toHTMLValidate(filename: string): R;
28
- toHTMLValidate(config: ConfigData): R;
29
- toHTMLValidate(config: ConfigData, filename: string): R;
30
- toHTMLValidate(error: Partial<Message>): R;
31
- toHTMLValidate(error: Partial<Message>, filename: string): R;
32
- toHTMLValidate(error: Partial<Message>, config: ConfigData): R;
33
- toHTMLValidate(error: Partial<Message>, config: ConfigData, filename: string): R;
34
- }
35
- }
36
- }
@@ -1,36 +0,0 @@
1
- import { o as Message, a as ConfigData, a9 as TokenType, L as Location } from './core.js';
2
-
3
- interface TokenMatcher {
4
- type: TokenType;
5
- location?: Partial<Location>;
6
- data?: any;
7
- }
8
- declare global {
9
- namespace jest {
10
- interface Matchers<R, T = {}> {
11
- toBeValid(): R;
12
- toBeInvalid(): R;
13
- toBeToken(expected: TokenMatcher): R;
14
- toHaveError(error: Partial<Message>): R;
15
- toHaveError(ruleId: string, message: string, context?: any): R;
16
- toHaveErrors(errors: Array<[string, string] | Record<string, unknown>>): R;
17
- /**
18
- * Validate string or HTMLElement.
19
- *
20
- * Test passes if result is valid.
21
- *
22
- * @param config - Optional HTML-Validate configuration object.
23
- * @param filename - Optional filename used when matching transformer and
24
- * loading configuration.
25
- */
26
- toHTMLValidate(): R;
27
- toHTMLValidate(filename: string): R;
28
- toHTMLValidate(config: ConfigData): R;
29
- toHTMLValidate(config: ConfigData, filename: string): R;
30
- toHTMLValidate(error: Partial<Message>): R;
31
- toHTMLValidate(error: Partial<Message>, filename: string): R;
32
- toHTMLValidate(error: Partial<Message>, config: ConfigData): R;
33
- toHTMLValidate(error: Partial<Message>, config: ConfigData, filename: string): R;
34
- }
35
- }
36
- }