-
Notifications
You must be signed in to change notification settings - Fork 594
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: adds fast-development-site for testing component libraries #7
Conversation
@@ -0,0 +1,2 @@ | |||
import Site, { ISiteProps, ISiteCategoryProps } from "./site"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to future proof, you can import and export the default, then do `export * from "./site";
@@ -0,0 +1,36 @@ | |||
import * as React from "react"; | |||
import {ISiteCategoryItemProps} from "./"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think item props should be defined in the category-item
} | ||
|
||
private renderComponent(): JSX.Element[] { | ||
return this.props.item.data.map((data: any, index: number) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should check to make sure this.props
has item
and that item.data
is an array
import {ISiteCategoryItemProps} from "./"; | ||
|
||
interface ICategoryItemProps { | ||
item: ISiteCategoryItemProps; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this component just expect ISiteCategoryItemProps
?
{ | ||
"extends": [ | ||
"@microsoft/fast-tslint-rules", | ||
"tslint-react" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fast-tslint-rules should already extend ts-lint react so I don't think you need this.
Closes #5