mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
added defination for react-typing-effect (#45664)
This commit is contained in:
parent
25e743aea3
commit
364f7f9fcd
19
types/react-typing-effect/index.d.ts
vendored
Normal file
19
types/react-typing-effect/index.d.ts
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
// Type definitions for react-typing-effect 2.0
|
||||
// Project: https://github.com/lamyfarai/react-typing-effect#readme
|
||||
// Definitions by: Debananda <https://github.com/Debananda>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
import { Component } from 'react';
|
||||
|
||||
export interface ReactTypingEffectProps {
|
||||
text: string | string[];
|
||||
staticText?: string;
|
||||
className?: string;
|
||||
speed?: number;
|
||||
eraseDelay?: number;
|
||||
typingDelay?: number;
|
||||
cursor?: string;
|
||||
cursorClassName?: string;
|
||||
}
|
||||
|
||||
export default class ReactTypingEffect extends Component<ReactTypingEffectProps> {}
|
||||
10
types/react-typing-effect/react-typing-effect-tests.tsx
Normal file
10
types/react-typing-effect/react-typing-effect-tests.tsx
Normal file
@ -0,0 +1,10 @@
|
||||
import * as React from 'react';
|
||||
import ReactTypingEffect from 'react-typing-effect';
|
||||
|
||||
class Test extends React.Component {
|
||||
render() {
|
||||
return (
|
||||
<ReactTypingEffect staticText="Hello" text={['Test', 'Again Test']} typingDelay={500} eraseDelay={1000} />
|
||||
);
|
||||
}
|
||||
}
|
||||
25
types/react-typing-effect/tsconfig.json
Normal file
25
types/react-typing-effect/tsconfig.json
Normal file
@ -0,0 +1,25 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6",
|
||||
"dom"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true,
|
||||
"jsx": "react"
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"react-typing-effect-tests.tsx"
|
||||
]
|
||||
}
|
||||
1
types/react-typing-effect/tslint.json
Normal file
1
types/react-typing-effect/tslint.json
Normal file
@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Loading…
Reference in New Issue
Block a user