Kaynağa Gözat

docs: fix stuff

Sv443 3 ay önce
ebeveyn
işleme
01ff2ca7de
2 değiştirilmiş dosya ile 14 ekleme ve 5 silme
  1. 6 2
      README-summary.md
  2. 8 3
      README.md

+ 6 - 2
README-summary.md

@@ -55,9 +55,10 @@ or view the documentation of previous major releases:
     - [`DataStoreSerializer`](https://github.com/Sv443-Network/UserUtils#datastoreserializer) - class for importing & exporting data of multiple DataStore instances, including compression, checksumming and running migrations
     - [`Dialog`](https://github.com/Sv443-Network/UserUtils#dialog) - class for creating custom modal dialogs with a promise-based API and a generic, default style
     - [`NanoEmitter`](https://github.com/Sv443-Network/UserUtils#nanoemitter) - tiny event emitter class with a focus on performance and simplicity (based on [nanoevents](https://npmjs.com/package/nanoevents))
+    - [`Debouncer`](https://github.com/Sv443-Network/UserUtils#debouncer) - class for debouncing function calls with a given timeout
+    - [`debounce()`](https://github.com/Sv443-Network/UserUtils#debounce) - function wrapper for the Debouncer class for easier usage
     - [`autoPlural()`](https://github.com/Sv443-Network/UserUtils#autoplural) - automatically pluralize a string
     - [`pauseFor()`](https://github.com/Sv443-Network/UserUtils#pausefor) - pause the execution of a function for a given amount of time
-    - [`debounce()`](https://github.com/Sv443-Network/UserUtils#debounce) - call a function only once in a series of calls, after or before a given timeout
     - [`fetchAdvanced()`](https://github.com/Sv443-Network/UserUtils#fetchadvanced) - wrapper around the fetch API with a timeout option
     - [`insertValues()`](https://github.com/Sv443-Network/UserUtils#insertvalues) - insert values into a string at specified placeholders
     - [`compress()`](https://github.com/Sv443-Network/UserUtils#compress) - compress a string with Gzip or Deflate
@@ -110,10 +111,13 @@ Shameless plug: I made a [template for userscripts in TypeScript](https://github
     Then import it in your script as usual:  
     
     ```ts
+    // on Node:
     import { addGlobalStyle } from "@sv443-network/userutils";
 
-    // or just import everything (not recommended because of worse treeshaking support):
+    // on Deno:
+    import { addGlobalStyle } from "jsr:@sv443-network/userutils";
 
+    // you can also import the entire library as an object (not recommended because of worse treeshaking support):
     import * as UserUtils from "@sv443-network/userutils";
     ```
 

+ 8 - 3
README.md

@@ -119,10 +119,13 @@ Shameless plug: I made a [template for userscripts in TypeScript](https://github
   Then import it in your script as usual:  
   
   ```ts
+  // on Node:
   import { addGlobalStyle } from "@sv443-network/userutils";
 
-  // or just import everything (not recommended because of worse treeshaking support):
+  // on Deno:
+  import { addGlobalStyle } from "jsr:@sv443-network/userutils";
 
+  // you can also import the entire library as an object (not recommended because of worse treeshaking support):
   import * as UserUtils from "@sv443-network/userutils";
   ```
 
@@ -187,8 +190,10 @@ Shameless plug: I made a [template for userscripts in TypeScript](https://github
 This library is written in TypeScript and contains builtin TypeScript declarations.  
   
 Each feature has example code that can be expanded by clicking on the text "Example - click to view".  
-The usages and examples are written in TypeScript and use ESM import syntax, but the library can also be used in plain JavaScript after removing the type annotations (and changing the imports if you are using CommonJS or the global declaration).  
-If the usage section contains multiple usages of the function, each occurrence represents an overload and you can choose which one you want to use.  
+The signatures and examples are written in TypeScript and use ESM import syntax, but the library can also be used in plain JavaScript after removing the type annotations (and changing the imports if you are using CommonJS or the global declaration).  
+  
+If the signature section contains multiple signatures of the function, each occurrence represents an overload and you can choose which one you want to use.  
+They will also be further explained in the description below that section.  
   
 Some features require the `@run-at` or `@grant` directives to be tweaked in the userscript header or have other specific requirements and limitations.  
 Those will be listed in a section marked by a warning emoji (⚠️) each.