Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: update schema to have negatedDescription only for type boolean #4280

Merged
merged 1 commit into from Feb 15, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 0 additions & 3 deletions bin/cli-flags.js
Expand Up @@ -166,8 +166,6 @@ module.exports = {
multiple: false,
description:
"Tells dev-server the number of times it should try to reconnect the client.",
negatedDescription:
"Tells dev-server to not to try to reconnect the client.",
path: "client.reconnect",
},
],
Expand Down Expand Up @@ -384,7 +382,6 @@ module.exports = {
values: ["only"],
multiple: false,
description: "Enables Hot Module Replacement.",
negatedDescription: "Disables Hot Module Replacement.",
path: "hot",
},
],
Expand Down
46 changes: 23 additions & 23 deletions lib/options.json
Expand Up @@ -28,7 +28,10 @@
"Bonjour": {
"anyOf": [
{
"type": "boolean"
"type": "boolean",
"cli": {
"negatedDescription": "Disallows to broadcasts dev server via ZeroConf networking on start."
}
},
{
"type": "object",
Expand All @@ -37,10 +40,7 @@
}
],
"description": "Allows to broadcasts dev server via ZeroConf networking on start.",
"link": " https://webpack.js.org/configuration/dev-server/#devserverbonjour",
"cli": {
"negatedDescription": "Disallows to broadcasts dev server via ZeroConf networking on start."
}
"link": " https://webpack.js.org/configuration/dev-server/#devserverbonjour"
},
"Client": {
"description": "Allows to specify options for client script in the browser or disable client script.",
Expand Down Expand Up @@ -122,16 +122,16 @@
"link": "https://webpack.js.org/configuration/dev-server/#reconnect",
"anyOf": [
{
"type": "boolean"
"type": "boolean",
"cli": {
"negatedDescription": "Tells dev-server to not to try to reconnect the client."
}
},
{
"type": "number",
"minimum": 0
}
],
"cli": {
"negatedDescription": "Tells dev-server to not to try to reconnect the client."
}
]
},
"ClientWebSocketTransport": {
"anyOf": [
Expand Down Expand Up @@ -481,17 +481,17 @@
"Hot": {
"anyOf": [
{
"type": "boolean"
"type": "boolean",
"cli": {
"negatedDescription": "Disables Hot Module Replacement."
}
},
{
"enum": ["only"]
}
],
"description": "Enables Hot Module Replacement.",
"link": "https://webpack.js.org/configuration/dev-server/#devserverhot",
"cli": {
"negatedDescription": "Disables Hot Module Replacement."
}
"link": "https://webpack.js.org/configuration/dev-server/#devserverhot"
},
"IPC": {
"anyOf": [
Expand Down Expand Up @@ -968,23 +968,26 @@
"serveIndex": {
"anyOf": [
{
"type": "boolean"
"type": "boolean",
"cli": {
"negatedDescription": "Does not tell dev server to use serveIndex middleware."
}
},
{
"type": "object",
"additionalProperties": true
}
],
"description": "Tells dev server to use serveIndex middleware when enabled.",
"cli": {
"negatedDescription": "Does not tell dev server to use serveIndex middleware."
},
"link": "https://webpack.js.org/configuration/dev-server/#serveindex"
},
"watch": {
"anyOf": [
{
"type": "boolean"
"type": "boolean",
"cli": {
"negatedDescription": "Does not watch for files in static content directory."
}
},
{
"type": "object",
Expand All @@ -993,9 +996,6 @@
}
],
"description": "Watches for files in static content directory.",
"cli": {
"negatedDescription": "Does not watch for files in static content directory."
},
"link": "https://webpack.js.org/configuration/dev-server/#watch"
}
}
Expand Down
23 changes: 15 additions & 8 deletions types/bin/cli-flags.d.ts
Expand Up @@ -114,13 +114,21 @@ declare const _exports: {
multiple: boolean;
};
"client-reconnect": {
configs: {
type: string;
multiple: boolean;
description: string;
negatedDescription: string;
path: string;
}[];
configs: (
| {
type: string;
multiple: boolean;
description: string;
negatedDescription: string;
path: string;
}
| {
type: string;
multiple: boolean;
description: string;
path: string;
}
)[];
description: string;
simpleType: string;
multiple: boolean;
Expand Down Expand Up @@ -289,7 +297,6 @@ declare const _exports: {
values: string[];
multiple: boolean;
description: string;
negatedDescription: string;
path: string;
}
)[];
Expand Down