You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: crates/tauri-cli/config.schema.json
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -160,7 +160,7 @@
160
160
"type": "object",
161
161
"properties": {
162
162
"windows": {
163
-
"description": "The windows configuration.",
163
+
"description": "The app windows configuration.",
164
164
"default": [],
165
165
"type": "array",
166
166
"items": {
@@ -225,6 +225,11 @@
225
225
"default": "main",
226
226
"type": "string"
227
227
},
228
+
"create": {
229
+
"description": "Whether Tauri should create this window at app startup or not.\n\n When this is set to `false` you must manually grab the config object via `app.config().app.windows`\n and create it with [`WebviewWindowBuilder::from_config`](https://docs.rs/tauri/2.0.0-rc/tauri/webview/struct.WebviewWindowBuilder.html#method.from_config).",
Copy file name to clipboardExpand all lines: crates/tauri-schema-generator/schemas/config.schema.json
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -160,7 +160,7 @@
160
160
"type": "object",
161
161
"properties": {
162
162
"windows": {
163
-
"description": "The windows configuration.",
163
+
"description": "The app windows configuration.",
164
164
"default": [],
165
165
"type": "array",
166
166
"items": {
@@ -225,6 +225,11 @@
225
225
"default": "main",
226
226
"type": "string"
227
227
},
228
+
"create": {
229
+
"description": "Whether Tauri should create this window at app startup or not.\n\n When this is set to `false` you must manually grab the config object via `app.config().app.windows`\n and create it with [`WebviewWindowBuilder::from_config`](https://docs.rs/tauri/2.0.0-rc/tauri/webview/struct.WebviewWindowBuilder.html#method.from_config).",
Copy file name to clipboardExpand all lines: crates/tauri-utils/src/config.rs
+10-1Lines changed: 10 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -1259,6 +1259,12 @@ pub struct WindowConfig {
1259
1259
/// The window identifier. It must be alphanumeric.
1260
1260
#[serde(default = "default_window_label")]
1261
1261
publabel:String,
1262
+
/// Whether Tauri should create this window at app startup or not.
1263
+
///
1264
+
/// When this is set to `false` you must manually grab the config object via `app.config().app.windows`
1265
+
/// and create it with [`WebviewWindowBuilder::from_config`](https://docs.rs/tauri/2.0.0-rc/tauri/webview/struct.WebviewWindowBuilder.html#method.from_config).
1266
+
#[serde(default = "default_true")]
1267
+
pubcreate:bool,
1262
1268
/// The window webview URL.
1263
1269
#[serde(default)]
1264
1270
puburl:WebviewUrl,
@@ -1455,6 +1461,7 @@ impl Default for WindowConfig {
1455
1461
Self{
1456
1462
label:default_window_label(),
1457
1463
url:WebviewUrl::default(),
1464
+
create:true,
1458
1465
user_agent:None,
1459
1466
drag_drop_enabled:true,
1460
1467
center:false,
@@ -1835,7 +1842,7 @@ impl Default for PatternKind {
0 commit comments