Skip to content
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: Indicator #21

Merged
merged 7 commits into from
Sep 8, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
further simplify
  • Loading branch information
Christoph Pader committed Sep 8, 2022
commit 28b91d6daa51201bb7c6510ec0207eaa10507ceb
8 changes: 5 additions & 3 deletions example/src/screens/GraphPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,11 @@ export function GraphPage() {
: undefined,
[points]
)
const range: GraphRange = useMemo(() => {
const range: GraphRange | undefined = useMemo(() => {
let r: GraphRange | undefined

if (enableRange) {
let r: GraphRange = {
r = {
y: {
min: -200,
max: 200,
Expand All @@ -58,7 +60,7 @@ export function GraphPage() {
}
}

return range
return r
}, [enableRange, highestDate, points])

return (
Expand Down