Patternfly-react: Add Typescript defintions

Created on 20 Jul 2017  路  3Comments  路  Source: patternfly/patternfly-react

  • add Typescript type definitions into the patternfly-react distributions (so that custom type definition is not needed in PF React Demo App)
enhancement

Most helpful comment

Hi @priley86,

Using patternfly-react and react with typescript without the definition makes it complicated to use. IMO, either the documentation should be really complete with details of the components and how to use them or have this definition to give auto-complete.

For example, I always have to browse the sources to find component props.

Using react with typescript is pretty common.

Maybe the problem is that the Storybook is not enough as a documentation to really have the component definition.

Cheers,

All 3 comments

I believe we voted against maintaining these definitions in PatternFly React b/c it would be too much of a burden at this point. We can reopen this later if this becomes an issue.

Hi @priley86,

Using patternfly-react and react with typescript without the definition makes it complicated to use. IMO, either the documentation should be really complete with details of the components and how to use them or have this definition to give auto-complete.

For example, I always have to browse the sources to find component props.

Using react with typescript is pretty common.

Maybe the problem is that the Storybook is not enough as a documentation to really have the component definition.

Cheers,

I'll just chime in here.. I know it is probably too late since you're working on PF4, but those definitions would make things so much easier!

Was this page helpful?
0 / 5 - 0 ratings