mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-06 07:47:04 +00:00
deep-freeze-es6: Provides its own types (#39629)
This commit is contained in:
committed by
Jesse Trinity
parent
82a40cf4c8
commit
0de0e14062
@@ -714,6 +714,12 @@
|
||||
"sourceRepoURL": "https://github.com/sindresorhus/decompress-response",
|
||||
"asOfVersion": "4.1.0"
|
||||
},
|
||||
{
|
||||
"libraryName": "deep-freeze-es6",
|
||||
"typingsPackageName": "deep-freeze-es6",
|
||||
"sourceRepoURL": "https://github.com/christophehurpeau/deep-freeze-es6",
|
||||
"asOfVersion": "1.1.0"
|
||||
},
|
||||
{
|
||||
"libraryName": "deepmerge",
|
||||
"typingsPackageName": "deepmerge",
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
import * as deepFreeze from "deep-freeze-es6";
|
||||
|
||||
class Foo {
|
||||
foo: string;
|
||||
}
|
||||
const foo: Foo = deepFreeze(new Foo());
|
||||
const foo2: Foo = deepFreeze({foo: "bar"});
|
||||
const obj: object = deepFreeze({count: 2});
|
||||
const items: Array<{id: number, name: string}> = deepFreeze([{id: 0, name: "first"}]);
|
||||
const map: Map<string, number> = deepFreeze(new Map());
|
||||
const set: Set<string> = deepFreeze(new Set());
|
||||
Vendored
-15
@@ -1,15 +0,0 @@
|
||||
// Type definitions for deep-freeze-es6 1.0
|
||||
// Project: https://github.com/christophehurpeau/deep-freeze-es6
|
||||
// Definitions by: Matt Bishop <https://github.com/mattbishop>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.2
|
||||
|
||||
/** Declaration file generated by dts-gen */
|
||||
|
||||
export = deepFreeze;
|
||||
|
||||
declare function deepFreeze<T>(obj: T): T;
|
||||
|
||||
declare namespace deepFreeze {
|
||||
const prototype: {};
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"deep-freeze-es6-tests.ts"
|
||||
]
|
||||
}
|
||||
@@ -1 +0,0 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Reference in New Issue
Block a user