the declarations .d.ts should be automatically generated from the relative .tsx? file
keep the @props and the export const Props to maintain compatibility for projects that are not in TS
specs
pick a component in JS and open a sub-issue called [Typo] TheComponentYouPicked
copy-paste the types from the .d.ts to the new .tsx? file
a. don't copy the tcomb type export as it's now inferred from TS (export const Props: { [key: string]: Type<any> };)
b. improve typings if you think they're not perfect but keep the same structure to avoid breaking changes (namespace, ..etc)
b. remove @skinnable
requirements
src
should be refactored in TS.d.ts
should be automatically generated from the relative.tsx?
file@props
and theexport const Props
to maintain compatibility for projects that are not in TSspecs
[Typo] TheComponentYouPicked
.d.ts
to the new.tsx?
file a. don't copy the tcomb type export as it's now inferred from TS (export const Props: { [key: string]: Type<any> };
) b. improve typings if you think they're not perfect but keep the same structure to avoid breaking changes (namespace
, ..etc) b. remove @skinnable.d.ts
files.tsx
b. if they testgetLocals
fix them usingenzyme
as done here: https://github.com/buildo/react-components/pull/1047/filesnpm test
b. runnpm start
and check that you component's examples still work with no error in consoleNOTE: If you have to add a
@types/x
dependency please add it without the^
as@types
doesn't follow semvermisc
{optional: other useful info}
sub-issues