w3c-html-validator 2.2.0 → 2.2.1

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/README.md CHANGED
@@ -203,7 +203,7 @@ type ValidatorResults = {
203
203
 
204
204
  ### 4. Mocha example
205
205
  ```javascript
206
- import assert from 'assert';
206
+ import assert from 'node:assert';
207
207
  import { w3cHtmlValidator } from 'w3c-html-validator';
208
208
 
209
209
  describe('Home page', () => {
@@ -1,4 +1,4 @@
1
- //! w3c-html-validator v2.2.0 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License
1
+ //! w3c-html-validator v2.2.1 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License
2
2
 
3
3
  export type ValidatorSettings = {
4
4
  html: string | null;
@@ -1,14 +1,14 @@
1
- //! w3c-html-validator v2.2.0 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License
1
+ //! w3c-html-validator v2.2.1 ~~ https://github.com/center-key/w3c-html-validator ~~ MIT License
2
2
 
3
3
  import { cliArgvUtil } from 'cli-argv-util';
4
4
  import { globSync } from 'glob';
5
5
  import chalk from 'chalk';
6
- import fs from 'fs';
6
+ import fs from 'node:fs';
7
7
  import log from 'fancy-log';
8
8
  import request from 'superagent';
9
9
  import slash from 'slash';
10
10
  const w3cHtmlValidator = {
11
- version: '2.2.0',
11
+ version: '2.2.1',
12
12
  checkUrl: 'https://validator.w3.org/nu/',
13
13
  defaultIgnoreList: [
14
14
  'with computed level',
@@ -98,7 +98,7 @@ const w3cHtmlValidator = {
98
98
  const readFile = (filename) => unixify(fs.readFileSync(filename, 'utf-8'));
99
99
  const inputHtml = settings.html ?? (filename ? readFile(filename) : null);
100
100
  const makePostRequest = () => request.post(settings.checkUrl)
101
- .set('Content-Type', 'text/html; encoding=utf-8')
101
+ .set('content-type', 'text/html; encoding=utf-8')
102
102
  .send(inputHtml);
103
103
  const makeGetRequest = () => request.get(settings.checkUrl)
104
104
  .query({ doc: settings.website });
@@ -155,7 +155,7 @@ const w3cHtmlValidator = {
155
155
  return validation.then(filterMessages).then(toValidatorResults).catch(handleError);
156
156
  },
157
157
  dryRunNotice() {
158
- log(chalk.gray('w3c-html-validator'), chalk.yellowBright('dry run mode:'), chalk.whiteBright('validation being bypassed'));
158
+ log(chalk.gray('w3c-html-validator'), chalk.yellowBright('dry run mode:'), chalk.whiteBright('skipping validation'));
159
159
  },
160
160
  summary(numFiles) {
161
161
  log(chalk.gray('w3c-html-validator'), chalk.magenta('files: ' + String(numFiles)));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "w3c-html-validator",
3
- "version": "2.2.0",
3
+ "version": "2.2.1",
4
4
  "description": "Check the markup validity of HTML files using the W3C validator",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -58,27 +58,27 @@
58
58
  },
59
59
  "dependencies": {
60
60
  "chalk": "~5.6",
61
- "cli-argv-util": "~1.4",
61
+ "cli-argv-util": "~1.5",
62
62
  "fancy-log": "~2.0",
63
63
  "glob": "~13.0",
64
64
  "slash": "~5.1",
65
65
  "superagent": "~10.3"
66
66
  },
67
67
  "devDependencies": {
68
- "@eslint/js": "~9.39",
68
+ "@eslint/js": "~10.0",
69
69
  "@types/fancy-log": "~2.0",
70
- "@types/node": "~25.0",
70
+ "@types/node": "~25.9",
71
71
  "@types/superagent": "~8.1",
72
72
  "add-dist-header": "~1.6",
73
73
  "assert-deep-strict-equal": "~1.2",
74
74
  "copy-file-util": "~1.3",
75
75
  "copy-folder-util": "~1.2",
76
- "eslint": "~9.39",
76
+ "eslint": "~10.4",
77
77
  "jshint": "~2.13",
78
78
  "mocha": "~11.7",
79
79
  "rimraf": "~6.1",
80
80
  "run-scripts-util": "~1.3",
81
- "typescript": "~5.9",
82
- "typescript-eslint": "~8.53"
81
+ "typescript": "~6.0",
82
+ "typescript-eslint": "~8.59"
83
83
  }
84
84
  }