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

Set up routing for judging #78

Merged
merged 4 commits into from
Nov 6, 2020
Merged

Set up routing for judging #78

merged 4 commits into from
Nov 6, 2020

Conversation

ianmah
Copy link
Contributor

@ianmah ianmah commented Nov 6, 2020

Closes #62

Creates new routes

  • /judging
  • /judging/view/:id
  • /judging/done
  • 404 page

Only includes JUDGING in sidebar when judging is open

@github-actions
Copy link

github-actions bot commented Nov 6, 2020

Visit the preview URL for this PR (updated for commit 2f61de1):

https://nwplus-ubc--pr78-judging-routing-1wndjvts.web.app

(expires Fri, 13 Nov 2020 03:09:24 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

@ianmah ianmah requested a review from jackyzha0 November 6, 2020 02:05
const [isJudgingEnabled, setIsJudgingEnabled] = useState(false)

useEffect(() => {
const unsubscribe = isJudgingOpen(setIsJudgingEnabled)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why the name change from isJudgingOpen to isJudgingDisabled?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

idk its overlapping with the firebase utility function name

src/pages/Judging/Done.js Outdated Show resolved Hide resolved
import styled from 'styled-components'
import Sidebar from './Sidebar'
import MobileMenuBar from './MobileMenuBar'
import { isJudgingOpen } from '../utility/firebase'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

alternatively, we can do import as here

Copy link
Contributor

@jackyzha0 jackyzha0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧼

@ianmah ianmah merged commit 8b5f793 into master Nov 6, 2020
@ianmah ianmah deleted the judging-routing branch November 6, 2020 03:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Judging routing
2 participants