Add index.d.ts (TypeScript)
See original GitHub issueEnvironment
- react-advanaced-form: 1.4.0
What
I suggest to add a separate index.d.ts
file for TypeScript annotations.
Why
To provide a more friendly on-boarding for TypeScript users. Also, in relation to #4, this suggestion doesn’t mean to use TypeScript for the library itself. Nothing should change under the hood.
Materials
How
This change is meant to be done gradually. Issue your pull requests to the master
with the changes done to index.d.ts
to get them reviewed.
Issue Analytics
- State:
- Created 5 years ago
- Comments:13 (7 by maintainers)
Top Results From Across the Web
Documentation - Creating .d.ts Files from .js files - TypeScript
Run the TypeScript compiler to generate the corresponding d.ts files for JS files; (optional) Edit your package.json to reference the types. Adding TypeScript....
Read more >What is the main usage of index.d.ts in Typescript?
*.d.ts files are used to provide typescript type information about a module that's written in JavaScript, for example, underscore / lodash ...
Read more >How do I get an index.d.ts file : r/typescript - Reddit
I'm trying to publish to DefinitelyTyped and noticed everyone is putting up one definitions file, index.d.ts , which contains a summary of ...
Read more >What is the correct way to write a .d.ts file for a node ... - GitHub
So, i am working on a small module written in JS, but I want to make it easy to use that module in...
Read more >Handbook - Creating .d.ts Files from .js files - TypeScript
Add TypeScript to your dev dependencies · Add a tsconfig.json to configure TypeScript · Run the TypeScript compiler to generate the corresponding d.ts...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@ell10t Yeah, the problem would be that developer is in charge of the property name under which the value of a field is stored. It would be impossible, and unnecessary, to assume the end field state. There may be, however, some smart usage of generics to achieve this dynamic property behavior.
I will try to read about it, and polish the typings further, so we could publish the first draft somewhere this months.
Sounds good to me.
No rush, just some notes:
ValidationMessages
andValidationSchema
name
children aren’t as strict as I would’ve hoped// ?
at the end of those lines