Procházet zdrojové kódy

docs: add destructuring example

Sven před 1 rokem
rodič
revize
e1a43ce208
1 změnil soubory, kde provedl 5 přidání a 0 odebrání
  1. 5 0
      README.greasyfork.md

+ 5 - 0
README.greasyfork.md

@@ -36,6 +36,11 @@ If you like using this library, please consider [supporting the development ❤
     Then, access the functions on the global variable `UserUtils`:
     ```ts
     UserUtils.addGlobalStyle("body { background-color: red; }");
+
+    // or using object destructuring:
+
+    const { clamp } = UserUtils;
+    console.log(clamp(1, 5, 10); // 5
     ```
 
 <br><br>