mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-11 11:50:54 +08:00
Properly name debounce test file
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
/// <reference path="debounce.d.ts" />
|
||||
|
||||
import debounce = require("debounce");
|
||||
|
||||
const doThings = () => 1;
|
||||
|
||||
debounce(function(){ doThings(); })();
|
||||
|
||||
debounce(function(){ doThings(); }, 1000)();
|
||||
|
||||
debounce(function(a: string){ doThings(); }, 1000)("foo");
|
||||
|
||||
// Immediate true should return the value
|
||||
const imm1: number = (debounce((x: number) => x * 2, 100, true))(2);
|
||||
Reference in New Issue
Block a user