mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-24 05:06:02 +08:00
Add types for rollup-plugin-json (#20799)
This commit is contained in:
committed by
Sheetal Nandi
parent
d37e6362bf
commit
dd56067216
15
types/rollup-plugin-json/index.d.ts
vendored
Normal file
15
types/rollup-plugin-json/index.d.ts
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
// Type definitions for rollup-plugin-json 2.3
|
||||
// Project: https://github.com/rollup/rollup-plugin-json#readme
|
||||
// Definitions by: Andy Mockler <https://github.com/asmockler>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
import { Plugin } from 'rollup';
|
||||
|
||||
export interface Options {
|
||||
include?: string | string[];
|
||||
exclude?: string | string[];
|
||||
preferConst?: boolean;
|
||||
indent?: string;
|
||||
}
|
||||
|
||||
export default function json(options?: Options): Plugin;
|
||||
3
types/rollup-plugin-json/rollup-plugin-json-tests.ts
Normal file
3
types/rollup-plugin-json/rollup-plugin-json-tests.ts
Normal file
@@ -0,0 +1,3 @@
|
||||
import json from 'rollup-plugin-json';
|
||||
|
||||
json(); // $ExpectType Plugin
|
||||
23
types/rollup-plugin-json/tsconfig.json
Normal file
23
types/rollup-plugin-json/tsconfig.json
Normal 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",
|
||||
"rollup-plugin-json-tests.ts"
|
||||
]
|
||||
}
|
||||
1
types/rollup-plugin-json/tslint.json
Normal file
1
types/rollup-plugin-json/tslint.json
Normal file
@@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Reference in New Issue
Block a user