Merge pull request #24420 from JoshuaKGoldberg/jsoneditor-for-react

Added jsoneditor-for-react types
This commit is contained in:
Paul van Brenk
2018-04-03 12:33:38 -07:00
committed by GitHub
4 changed files with 46 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
// Type definitions for jsoneditor-for-react 0.0
// Project: https://github.com/mixj93/jsoneditor-for-react#readme
// Definitions by: JoshGoldberg <https://github.com/joshuakgoldberg>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.6
import * as React from "react";
import JSONEditor, { JSONEditorOptions } from "jsoneditor";
export interface ReactJsonEditorProps {
values: {};
}
export default class ReactJsoneditor extends React.Component<ReactJsonEditorProps> {
private editor?: JSONEditor;
private options?: JSONEditorOptions;
}
@@ -0,0 +1,4 @@
import * as React from "react";
import ReactJsonEditor from "jsoneditor-for-react";
const component = <ReactJsonEditor values={{}} />;
+24
View File
@@ -0,0 +1,24 @@
{
"compilerOptions": {
"module": "commonjs",
"lib": [
"es6"
],
"noImplicitAny": true,
"noImplicitThis": true,
"strictNullChecks": true,
"strictFunctionTypes": true,
"baseUrl": "../",
"jsx": "react",
"typeRoots": [
"../"
],
"types": [],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.d.ts",
"jsoneditor-for-react-tests.tsx"
]
}
+1
View File
@@ -0,0 +1 @@
{ "extends": "dtslint/dt.json" }