stylelint-webpack-plugin 2.1.0 → 2.1.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/CHANGELOG.md CHANGED
@@ -2,6 +2,19 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [2.1.1](https://github.com/webpack-contrib/stylelint-webpack-plugin/compare/v1.2.3...v2.1.1) (2020-10-14)
6
+
7
+
8
+ ### Features
9
+
10
+ * support typescript ([#213](https://github.com/webpack-contrib/stylelint-webpack-plugin/issues/213)) ([b7dfa19](https://github.com/webpack-contrib/stylelint-webpack-plugin/commit/b7dfa195b7836bad7ac94a64a0c0a6163021a3e7))
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * avoiding https://github.com/mrmlnc/fast-glob/issues/158 ([#209](https://github.com/webpack-contrib/stylelint-webpack-plugin/issues/209)) ([14ae30d](https://github.com/webpack-contrib/stylelint-webpack-plugin/commit/14ae30df8a6d6b629c4e1fa647b4c6989377aec8))
16
+ * use better micromatch extglobs ([#216](https://github.com/webpack-contrib/stylelint-webpack-plugin/issues/216)) ([a70ed3d](https://github.com/webpack-contrib/stylelint-webpack-plugin/commit/a70ed3d6b6d8da90bf4dc371057cbe1433b4558d))
17
+
5
18
  ## [2.1.0](https://github.com/webpack-contrib/stylelint-webpack-plugin/compare/v1.2.3...v2.1.0) (2020-06-17)
6
19
 
7
20
 
@@ -23,12 +23,18 @@ export default class LintDirtyModulesPlugin {
23
23
  */
24
24
  apply(compilation: Compiler, callback: LinterCallback): void;
25
25
  /**
26
- * @param {Map<string, number>} fileTimestamps
26
+ * @param {Map<string, number|FileSystemInfoEntry>} fileTimestamps
27
27
  * @param {string | ReadonlyArray<string>} glob
28
28
  * @returns {Array<string>}
29
29
  */
30
30
  getChangedFiles(
31
- fileTimestamps: Map<string, number>,
31
+ fileTimestamps: Map<
32
+ string,
33
+ | number
34
+ | Partial<{
35
+ timestamp: number;
36
+ }>
37
+ >,
32
38
  glob: string | ReadonlyArray<string>
33
39
  ): Array<string>;
34
40
  }
@@ -68,7 +68,7 @@ class LintDirtyModulesPlugin {
68
68
  }
69
69
  }
70
70
  /**
71
- * @param {Map<string, number>} fileTimestamps
71
+ * @param {Map<string, number|FileSystemInfoEntry>} fileTimestamps
72
72
  * @param {string | ReadonlyArray<string>} glob
73
73
  * @returns {Array<string>}
74
74
  */
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.default = getOptions;
7
7
 
8
- var _schemaUtils = _interopRequireDefault(require("schema-utils"));
8
+ var _schemaUtils = require("schema-utils");
9
9
 
10
10
  var _options = _interopRequireDefault(require("./options.json"));
11
11
 
@@ -33,13 +33,13 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
33
33
  */
34
34
  function getOptions(pluginOptions) {
35
35
  const options = {
36
- files: '**/*.s?(c|a)ss',
36
+ files: '**/*.(s(c|a)ss|css)',
37
37
  formatter: 'string',
38
38
  stylelintPath: 'stylelint',
39
39
  ...pluginOptions
40
40
  }; // @ts-ignore
41
41
 
42
- (0, _schemaUtils.default)(_options.default, options, {
42
+ (0, _schemaUtils.validate)(_options.default, options, {
43
43
  name: 'Stylelint Webpack Plugin',
44
44
  baseDataPath: 'options'
45
45
  }); // eslint-disable-next-line
package/dist/linter.js CHANGED
@@ -51,11 +51,13 @@ function linter(lint, options, compiler, callback) {
51
51
  } = parseResults(options, results));
52
52
  compiler.hooks.afterEmit.tapAsync('StylelintWebpackPlugin', (compilation, next) => {
53
53
  if (warnings.length) {
54
+ // @ts-ignore
54
55
  compilation.warnings.push(_StylelintError.default.format(options, warnings));
55
56
  warnings = [];
56
57
  }
57
58
 
58
59
  if (errors.length) {
60
+ // @ts-ignore
59
61
  compilation.errors.push(_StylelintError.default.format(options, errors));
60
62
  errors = [];
61
63
  }
@@ -72,6 +74,7 @@ function linter(lint, options, compiler, callback) {
72
74
  }
73
75
  }).catch(e => {
74
76
  compiler.hooks.afterEmit.tapAsync('StylelintWebpackPlugin', (compilation, next) => {
77
+ // @ts-ignore
75
78
  compilation.errors.push(new _StylelintError.default(e.message));
76
79
  next();
77
80
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "stylelint-webpack-plugin",
3
- "version": "2.1.0",
3
+ "version": "2.1.1",
4
4
  "description": "A Stylelint plugin for webpack",
5
5
  "license": "MIT",
6
6
  "repository": "webpack-contrib/stylelint-webpack-plugin",
@@ -52,38 +52,38 @@
52
52
  "dependencies": {
53
53
  "arrify": "^2.0.1",
54
54
  "micromatch": "^4.0.2",
55
- "schema-utils": "^2.7.0"
55
+ "schema-utils": "^3.0.0"
56
56
  },
57
57
  "devDependencies": {
58
- "@babel/cli": "^7.10.1",
59
- "@babel/core": "^7.10.2",
60
- "@babel/preset-env": "^7.10.2",
61
- "@commitlint/cli": "^8.3.5",
62
- "@commitlint/config-conventional": "^8.3.4",
58
+ "@babel/cli": "^7.12.0",
59
+ "@babel/core": "^7.12.0",
60
+ "@babel/preset-env": "^7.12.0",
61
+ "@commitlint/cli": "^11.0.0",
62
+ "@commitlint/config-conventional": "^11.0.0",
63
63
  "@types/micromatch": "^4.0.1",
64
64
  "@types/stylelint": "^9.10.1",
65
- "@types/webpack": "^4.41.17",
65
+ "@types/webpack": "^4.41.20",
66
66
  "@webpack-contrib/defaults": "^6.3.0",
67
67
  "@webpack-contrib/eslint-config-webpack": "^3.0.0",
68
68
  "babel-eslint": "^10.1.0",
69
- "babel-jest": "^26.0.1",
69
+ "babel-jest": "^26.5.2",
70
70
  "cross-env": "^7.0.2",
71
- "del": "^5.1.0",
71
+ "del": "^6.0.0",
72
72
  "del-cli": "^3.0.1",
73
- "eslint": "^7.2.0",
74
- "eslint-config-prettier": "^6.11.0",
73
+ "eslint": "^7.11.0",
74
+ "eslint-config-prettier": "^6.12.0",
75
75
  "eslint-friendly-formatter": "^4.0.1",
76
- "eslint-plugin-import": "^2.21.2",
77
- "file-loader": "^6.0.0",
78
- "husky": "^4.2.5",
79
- "jest": "^26.0.1",
80
- "lint-staged": "^10.2.10",
76
+ "eslint-plugin-import": "^2.22.1",
77
+ "file-loader": "^6.1.1",
78
+ "husky": "^4.3.0",
79
+ "jest": "^26.5.3",
80
+ "lint-staged": "^10.4.0",
81
81
  "npm-run-all": "^4.1.5",
82
- "prettier": "^2.0.5",
83
- "standard-version": "^8.0.0",
84
- "stylelint": "^13.6.0",
85
- "typescript": "^3.9.5",
86
- "webpack": "^4.43.0"
82
+ "prettier": "^2.1.2",
83
+ "standard-version": "^9.0.0",
84
+ "stylelint": "^13.7.2",
85
+ "typescript": "^4.0.3",
86
+ "webpack": "^5.1.0"
87
87
  },
88
88
  "keywords": [
89
89
  "stylelint",