From 68589e968cbc043f35c2948a9c90293b6f5f9cb9 Mon Sep 17 00:00:00 2001 From: Arsen Mirzaev Tatyano-Muradovich Date: Sat, 11 Jan 2025 22:39:38 +0700 Subject: [PATCH] remove `default` + reminified --- damper.min.mjs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/damper.min.mjs b/damper.min.mjs index a8c8ff6..2fe91e8 100644 --- a/damper.min.mjs +++ b/damper.min.mjs @@ -1,4 +1,5 @@ -"use strict";/** +"use strict"; +/** * @name Damper * * @description @@ -32,5 +33,4 @@ * * @license http://www.wtfpl.net/ Do What The Fuck You Want To Public License * @author Arsen Mirzaev Tatyano-Muradovich - */ -export default function e(e,p=300,t){let i;return(...s)=>new Promise(((u,l)=>{clearTimeout(i),"number"==typeof t&&s[t]?("number"==typeof t&&(s=[...s.splice(0,t),...s.splice(t+1)]),s.push(u,l),e.apply(this,s)):("number"==typeof t&&(s=[...s.splice(0,t),...s.splice(t+1)]),s.push(u,l),i=setTimeout((()=>e.apply(this,s)),p))}))} \ No newline at end of file + */export function damper(e,p=300,t){let s;return(...i)=>new Promise(((r,u)=>{clearTimeout(s),"number"==typeof t&&i[t]?("number"==typeof t&&(i=[...i.splice(0,t),...i.splice(t+1)]),i.push(r,u),e.apply(this,i)):("number"==typeof t&&(i=[...i.splice(0,t),...i.splice(t+1)]),i.push(r,u),s=setTimeout((()=>e.apply(this,i)),p))}))} \ No newline at end of file