@markuplint/ml-config 4.5.1 → 4.6.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/lib/merge-config.js +1 -0
- package/lib/types.d.ts +2 -1
- package/package.json +6 -6
package/lib/merge-config.js
CHANGED
|
@@ -14,6 +14,7 @@ export function mergeConfig(a, b) {
|
|
|
14
14
|
a.rules, b.rules),
|
|
15
15
|
nodeRules: concatArray(a.nodeRules, b.nodeRules),
|
|
16
16
|
childNodeRules: concatArray(a.childNodeRules, b.childNodeRules),
|
|
17
|
+
overrideMode: b.overrideMode ?? a.overrideMode,
|
|
17
18
|
overrides: mergeObject(a.overrides, b.overrides),
|
|
18
19
|
// delete all
|
|
19
20
|
extends: undefined,
|
package/lib/types.d.ts
CHANGED
|
@@ -14,6 +14,7 @@ export type Config = {
|
|
|
14
14
|
readonly rules?: Rules;
|
|
15
15
|
readonly nodeRules?: readonly NodeRule[];
|
|
16
16
|
readonly childNodeRules?: readonly ChildNodeRule[];
|
|
17
|
+
readonly overrideMode?: 'merge' | 'reset';
|
|
17
18
|
readonly overrides?: Readonly<Record<string, OverrideConfig>>;
|
|
18
19
|
};
|
|
19
20
|
export type PrimitiveScalar = string | number | boolean;
|
|
@@ -23,7 +24,7 @@ export type PlainData = Nullable<PrimitiveScalar> | readonly PlainData[] | {
|
|
|
23
24
|
export type NonNullablePlainData = PrimitiveScalar | readonly NonNullablePlainData[] | {
|
|
24
25
|
readonly [key: string]: NonNullablePlainData;
|
|
25
26
|
};
|
|
26
|
-
export type OverrideConfig = Omit<Config, '$schema' | 'extends' | 'overrides'>;
|
|
27
|
+
export type OverrideConfig = Omit<Config, '$schema' | 'extends' | 'overrideMode' | 'overrides'>;
|
|
27
28
|
export type PluginConfig = {
|
|
28
29
|
readonly name: string;
|
|
29
30
|
readonly settings: Readonly<Record<string, NonNullablePlainData>>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@markuplint/ml-config",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.6.0",
|
|
4
4
|
"description": "JSON Schema and TypeScript types of markuplint configure JSON",
|
|
5
5
|
"repository": "git@github.com:markuplint/markuplint.git",
|
|
6
6
|
"author": "Yusuke Hirao <yusukehirao@me.com>",
|
|
@@ -24,14 +24,14 @@
|
|
|
24
24
|
"clean": "tsc --build --clean"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@markuplint/ml-ast": "4.
|
|
28
|
-
"@markuplint/selector": "4.
|
|
29
|
-
"@markuplint/shared": "4.
|
|
27
|
+
"@markuplint/ml-ast": "4.3.0",
|
|
28
|
+
"@markuplint/selector": "4.6.0",
|
|
29
|
+
"@markuplint/shared": "4.3.0",
|
|
30
30
|
"@types/mustache": "4.2.5",
|
|
31
31
|
"deepmerge": "4.3.1",
|
|
32
32
|
"is-plain-object": "5.0.0",
|
|
33
33
|
"mustache": "4.2.0",
|
|
34
|
-
"type-fest": "4.
|
|
34
|
+
"type-fest": "4.18.1"
|
|
35
35
|
},
|
|
36
|
-
"gitHead": "
|
|
36
|
+
"gitHead": "b8d7bae9bdcdad63ff79abe21b88be12abde3633"
|
|
37
37
|
}
|