@dragonish/arrive-type
Version:
generic type library of arrive package
52 lines (37 loc) • 780 B
Markdown
file:
```json
{
"compilerOptions": {
"typeRoots": [
"./node_modules/@types",
"./node_modules/@dragonish"
]
}
}
```
```typescript
document.arrive<HTMLImageElement>('img', img => {
const src = img.src;
// ...
});
```
Async/await and promise support:
```typescript
const img = await document.arrive<HTMLImageElement>('img');
const src = img.src;
// ...
```
- [uzairfarooq/arrive](https://github.com/uzairfarooq/arrive)
- [DefinitelyTyped/DefinitelyTyped](https://github.com/DefinitelyTyped/DefinitelyTyped)
[ ](./LICENSE)
generic type library of `arrive` package.
```shell
npm install arrive
npm install @dragonish/arrive-type -D
```
Add to the `tsconfig.json`