-
Notifications
You must be signed in to change notification settings - Fork 9
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: add tictactoe example by hackyguru #292
base: master
Are you sure you want to change the base?
Conversation
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.
we can remove this
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.
we can remove this
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.
hm. not a fan of using tailwindcss extensively but also relying on native CSS heavily at the same time
let b = {}; | ||
let o = false; |
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.
nit: some let
keywords can be swapped for const
keywords in the codebase
import ShortUniqueId from 'short-unique-id'; | ||
import Router from 'next/router'; | ||
|
||
export default function Hero() { |
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.
what is the relevance of this component name
if (room === null) { | ||
setRoom(uid.rnd()); | ||
} | ||
}, []); |
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.
we should add room
as a dependency to the useEffect
sessionStorage.setItem('roomId', room); | ||
sessionStorage.setItem('player', 'x'); |
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.
would be cool to use enums for this
}; | ||
|
||
const handleJoinGameClick = () => { | ||
setGame('join'); |
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.
similar comment as above re enums
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.
this file can be broken down into more files for more readability
@vpavlin currently there is a problem with hosting Next.js apps - still didn't figure solution |
Can you elaborate the problem (in an issue if necessary)? |
@weboko @danisharora099 Can you check? I am not sure if I missed anything necessary to get this in and deployed!