-
Notifications
You must be signed in to change notification settings - Fork 29
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
Table and AreaChart components for React #362
Conversation
🦋 Changeset detectedLatest commit: 0538c15 The changes in this PR will be included in the next version bump. This PR includes changesets to release 5 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
756fd69
to
a666591
Compare
e55b4ea
to
9ab566b
Compare
Don't bundle all the components in this PR, merge as you go so that we can begin QAing as we ship stuff. Also easier to review. |
bc298f1
to
89aae27
Compare
705e701
to
db0ae52
Compare
89aae27
to
47be7b5
Compare
|
||
function QueryTable({ queryPath, params, download = false, tanstaskQueryOptions, ...rest }: Props) { | ||
const { data, isLoading, error, download: downloadFn } = useQuery({ queryPath, params, tanstaskQueryOptions }) | ||
const result = useMemo(() => new QueryResult(data), [data]) |
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 useQuery
return query result? I guess is something we're going to do everywhere
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.
Yeah I think it should...
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.
just wrap useQuery in another hook and use that to avoid repetition. We can explore a breaking change further down the line.
packages/client/react/src/lib/visualizations/raw/charts/AreaChart.tsx
Outdated
Show resolved
Hide resolved
@csansoon 🔴 1k lines should be enough for this PR |
21eec58
to
93b36a0
Compare
66a0b79
to
ea94dca
Compare
d5617b6
to
e83100e
Compare
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.
looks good!
15f5fae
to
de462fa
Compare
Describe your changes
Added support for visualization components to react.
For this one, only Table and AreaChart were implemented. More visualizations will be implemented in a different PR.