Browse Source

refactor: remove unnecessary hashes around raw str (#10273)

Hamir Mahal 1 year ago
parent
commit
26f2e19a4f
2 changed files with 4 additions and 4 deletions
  1. 2 2
      core/tauri/build.rs
  2. 2 2
      core/tauri/src/manager/webview.rs

+ 2 - 2
core/tauri/build.rs

@@ -321,10 +321,10 @@ fn main() {
 }
 
 fn define_permissions(out_dir: &Path) {
-  let license_header = r#"# Copyright 2019-2024 Tauri Programme within The Commons Conservancy
+  let license_header = r"# Copyright 2019-2024 Tauri Programme within The Commons Conservancy
 # SPDX-License-Identifier: Apache-2.0
 # SPDX-License-Identifier: MIT
-"#;
+";
 
   for (plugin, commands) in PLUGINS {
     let permissions_out_dir = out_dir.join("permissions").join(plugin);

+ 2 - 2
core/tauri/src/manager/webview.rs

@@ -165,7 +165,7 @@ impl<R: Runtime> WebviewManager<R> {
     }
     webview_attributes = webview_attributes
       .initialization_script(
-        r#"
+        r"
         Object.defineProperty(window, 'isTauri', {
           value: true,
         });
@@ -177,7 +177,7 @@ impl<R: Runtime> WebviewManager<R> {
             }
           })
         }
-      "#,
+      ",
       )
       .initialization_script(&self.invoke_initialization_script)
       .initialization_script(&format!(