Merge pull request #33054 from ZhangYiJiang/add-no-scroll

[no-scroll] Add no-scroll typing
This commit is contained in:
Mine Starks
2019-02-14 11:25:04 -08:00
committed by GitHub
4 changed files with 45 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
// Type definitions for no-scroll 2.1
// Project: https://github.com/davidtheclark/no-scroll
// Definitions by: Zhang Yi Jiang <https://github.com/ZhangYiJiang>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// Module is exported as global object outside of module loader environment
export as namespace noScroll;
interface NoScroll {
off(): void;
on(): void;
toggle(): void;
}
declare const noScroll: NoScroll;
export = noScroll;
+5
View File
@@ -0,0 +1,5 @@
import * as noScroll from 'no-scroll';
noScroll.on();
noScroll.off();
noScroll.toggle();
+23
View File
@@ -0,0 +1,23 @@
{
"compilerOptions": {
"module": "commonjs",
"lib": [
"es6"
],
"noImplicitAny": true,
"noImplicitThis": true,
"strictNullChecks": true,
"strictFunctionTypes": true,
"baseUrl": "../",
"typeRoots": [
"../"
],
"types": [],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.d.ts",
"no-scroll-tests.ts"
]
}
+1
View File
@@ -0,0 +1 @@
{ "extends": "dtslint/dt.json" }