Basic Functions (For userscripts)

Useful functions for myself

2024-03-24 يوللانغان نەشرى. ئەڭ يېڭى نەشرىنى كۆرۈش.

بۇلار بۇ قوليازمىنىڭ كود يېڭىلانغان نەشرىلىرى. بارلىق نەشرىنى كۆرسىتىش

  • v1.10.4 2025-05-29
    • bug fix
  • v1.10.3 2025-05-29
    • improvement: provide default_pool from FunctionLoader as exported variables
  • v1.10.2 2025-05-29
    • improvement: now FunctionLoader.FuncPool.#load do not catch errors by default; set pool.catch_errors = true to enable error catching
  • v1.10.1 2025-05-29
    • bug fix: variable name mistake
  • v1.10 2025-05-29
    • feat: require now supports wait for oFunc to be loaded and return a promise that resolves the return value by setting the second param wait=true
  • v1.9.3 2025-05-27
    • code quality: fixed some JSDoc comments
  • v1.9.2 2025-05-16
    • bug fix: FuncPool.errors not initialized
  • v1.9.1 2025-05-16
    • bug fix: new keyword missing for CustomEvent constructor
  • v1.9 2025-05-16
    • feat: error handling support for FunctionLoader.FuncPool
  • v1.8.1 2025-03-23
    • bug fix: mis-use of innerText and innerHTML in addStyle
  • v1.8 2025-03-04
    • improvement: now checkers run before detectDom runs
  • v1.7.1 2025-03-03
    • improvement: set oFunc's return value to FunctionLoader.FuncPool.CheckerNotPass when checker doesn't pass in FunctionLoader.#load
  • v1.7 2025-03-03
    • feat: FunctionLoader.FuncPool.load returns a promise that will resolve when all provided oFuncs loaded
  • v1.6.1 2025-03-03
    • bug fix: FunctionLoader.FuncPool constructor param default value missing
  • v1.6 2025-03-03
    • feat: new FunctionLoader.FunctionPool now accepts explicitly providing GM_getValue, GM_setValue, GM_deleteValue, and GM_listValues
  • v1.5 2025-03-01
    • feat: added this value customization for testChecker and provides oFunc as this value for testChecker in oFunc loading process
  • v1.4.1 2025-02-24
    • maintainence: jsdoc improvements
  • v1.4 2025-02-06
    • improvement: replace substorage with params in FunctionLoader
  • v1.3 2025-02-03
    • feat: diabled property of oFunc for FunctionLoader
  • v1.2 2025-02-01
    • feat: substorage support for FunctionLoader
  • v1.1.1 2025-01-28
    • bug fix: JSDoc annotation for $ and $All
  • v1.1 2025-01-25
    • maintainence: replace all TAB with four whitespaces
  • v1.0.1 2025-01-25
    • bug fix: incorrect parseArgs argument order
  • v1.0 2025-01-25
    • maintainence: Added JSdoc annotations
  • v0.10.3 2025-01-24
    • bug fix: incorrect exports
  • v0.10.2 2025-01-24
    • bug fix: isLoaded not exported
  • v0.10.1 2025-01-24
    • improvement: isLoaded for FunctionLoader
  • v0.10 2025-01-24
    • improvement: new FunctionLoader
  • v0.9 2024-12-21
    • improvement: loadFuncs now returns an instance of EventTarget, which dispatches two events func_load and all_load
  • v0.8.13 2024-11-23
    • improvement: always execute callback after current eventloop in detectDom
  • v0.8.12 2024-09-08
    • bug fix: multiple execution
  • v0.8.11 2024-09-07
    • bug fix: oFunc being loaded multiple times when being a dependency
  • v0.8.10 2024-09-07
    • oFunc.dependencies support: all oFuncs specified in oFunc.dependencies by their id will be loaded before oFunc.func itself executed
  • v0.8.9 2024-09-07
    • now loadFuncs has better support for AsyncFunction: get their return value using await
  • v0.8.8 2024-09-06
    • loadFuncs now supports objFunc.readonly to make their return value write-protected, and allows modifing return objects when objFunc.readonly is falsy
  • v0.8.7 2024-09-06
    • loadFuncs now saves return value only if objFunc.id exists and objFunc.func returns an object
  • v0.8.6.3 2024-03-24
    • bug fix for detectDom
  • v0.8.6.2 2024-03-24
    • bug fix for detectDom
  • v0.8.6.1 2024-03-24
    • queueTask now supports specifying different queue's sleep and max argument
  • v0.8.6 2024-03-24
    • added queueTask
  • v0.8.5.2 2024-03-23
    • bug fix
  • v0.8.5.1 2024-03-23
    • loadFuncs now accept detectDom property in both array format (for multiple selectors to detect) and string format (for single selector to detect) in objFunc
  • v0.8.5 2024-03-23
    • detectDom now works in both callback and promise mode, and prefers promise mode.
  • v0.8.4.2 2024-03-22
    • bug fix
  • v0.8.4.1 2024-03-22
    • bug fix
  • v0.8.4 2024-03-22
    • Assert support
    • testChecker, registerChecker, loadFuncs support
  • v0.8.3 2023-12-29
    • Update getUrlArgv
  • v0.8.2 2023-11-19

    detectDom: added support for attributes change

  • v0.8.1 2023-09-15

    bug fix

  • v0.8 2023-09-15

    detectDom now supports matching multiple selectors in one time

بارلىق قوليازما نەشرىلىرىنى كۆرسىتىش