Typescript specific docs
Opened this issue · 3 comments
Docs for usage with typescript: It would be great to have the opportunity to write docs for typescript-specific stuff for particular functions. Some functions when using with typescript really need to be explained.
I'm thinking we can add comments between any imports and the exports of the type files. eg
import { Ord } from './util/tools';
/*
* Comments go here
*/
export function max<T extends Ord>(a: T, b: T): T;
export function max<T extends Ord>(a: T): (b: T) => T;
We can then grab them in the build script and include them in the packaged index.d.ts. At some point we can get them into the ramda website as well.
Does anyone have any thoughts on more general ramda related typescript docs/thoughts/guidelines? Should we add a TYPESCRIPT.md?
Also as an idea, maybe we can use tests for it somehow? In tests(in DefinitelyTyped) there are examples how to use it with typescript with comments.
transferred from the main repo, feel free to close if we want to track this another way