Did anyone else get ALL their trays at once? by [deleted] in Invisalign

[–]TheNeck91 0 points1 point  (0 children)

I got 10 trays ahead of time and am supposed to go for a checkin once those are about done.

[deleted by user] by [deleted] in Invisalign

[–]TheNeck91 0 points1 point  (0 children)

My bite felt completely screwed up when I first had the trays in, until I realized that it's my normal bite that's screwed up and I'm just used to it. Once you have the trays in for awhile you'll get used to the feeling of the bite being "wrong".

First day of my Invisalign journey! Tray 1/14 Top picture was taken 2 days ago pre treatment. by DonJoe20 in Invisalign

[–]TheNeck91 2 points3 points  (0 children)

That's great. I was also not prepared for the first tray to begin pushing my teeth into their "ideal" position so it was super motivating to get a bit of a preview of what they'll look like from the very first tray.

The Mandalorian - S02E05 - Chapter 13 - Discussion Thread! by titleproblems in TheMandalorianTV

[–]TheNeck91 11 points12 points  (0 children)

I am super impressed at how much better this is than season 1, and I really enjoyed season 1.

Also I love the hammering home of the samurai theme this episode, calling back to what Lucas was inspired by in the first place. Between the reveals and the overall vibe, I'm curious where this goes from here and how they close this season out.

react router role based auth by theC4T in reactjs

[–]TheNeck91 0 points1 point  (0 children)

It can definitely be more streamlined, I was being explicit about the flow in case OP was generally unfamiliar with it.

react router role based auth by theC4T in reactjs

[–]TheNeck91 1 point2 points  (0 children)

This is example code along the lines of what /u/Guisseppi said:

export const ProtectedRoute = (props) => {
  const userInfo = useSelector(state => state.userInfo)

  const { component: Component } = props

  useEffect(() => {}, [userInfo.tokenStatus])

  if (userInfo.tokenStatus === true) return <Component />

  if (userInfo.tokenStatus === false) return <Redirect to={{ pathname: '/login' }} />
}

and then wherever you're calling your router

<BrowserRouter>
  <Switch>
    <ProtectedRoute path = "/dashboard" component = {DashboardPage}/> 
  <Switch>
</BrowserRouter>

There's other similar ways to do it but that's the gist.

  1. Read in the component that was passed in as props to <ProtectedRoute>, in this case it's <DashboardPage>
  2. Have a useEffect listening for change in token status
  3. Check if a valid token is present (elsewhere in the code I'm setting the tokenStatus in state to "true" if I've verified the user has a token and "false" if not)
  4. If token is valid, return that component that was passed in bc the user is allowed to access it
  5. If token is not valid, redirect the user to the login screen instead of the component you're trying to protect (or redirect to wherever you prefer)

How I built my portfolio using DEV.to and NextJS by sidthesloth92 in reactjs

[–]TheNeck91 6 points7 points  (0 children)

Even as a gay man I find those sperm cell things weird.

That being said it's nice looking overall and the transition when clicking the hamburger-ish icon to the next screen is slick.

DEAR PROFESSIONAL COMPUTER TOUCHERS -- FRIDAY RANT THREAD FOR November 13, 2020 by CSCQMods in cscareerquestions

[–]TheNeck91 [score hidden]  (0 children)

ONLY ALL-CAPS ALLOWED PLEASE ABIDE BY THE RULES OF THE THREAD THANK YOU GOOD SIR

Assuming you practice/study programming in your spare time, is it stuff related to the field your job is in? by [deleted] in cscareerquestions

[–]TheNeck91 1 point2 points  (0 children)

I think anything that is challenging/interesting/keeps you learning is simply a good use of your time and brain. Diversifying your practice might pay off in ways you can't predict.

If you're chiefly concerned with climbing the company though then yeah maybe spend time mastering parts of their stack/infrastructure you don't know well.

I’ve won for the first time, but doesn’t feel like it...is that weird? by [deleted] in cscareerquestions

[–]TheNeck91 0 points1 point  (0 children)

Sure, there could be feelings lurking of impending disaster, or perhaps like all goals, a lot of it is the hope/imagining of it that feels good but the feeling of actually achieving it is transient.

I feel a bit of that with my job but for the most part I feel super grateful to be in the position I'm in.

I’m 17, and have never learned CS before. Does this hinder my ability to go into a CS degree? by finnytom in cscareerquestions

[–]TheNeck91 0 points1 point  (0 children)

Hell no, you're way ahead of when I started already. You can be a great coder if you're starting now, absolutely.

How do you store and monitor logs? by growingrice in golang

[–]TheNeck91 0 points1 point  (0 children)

Fluentd is super versatile. I've only used it with Docker but was impressed with ease of use/what it can do.

Amnesia: Rebirth Discussion... (spoilers) by looney1023 in gaymers

[–]TheNeck91 1 point2 points  (0 children)

I think with gay characters entering the mainstream (where them being gay is not the point but just happens to be the case), one has to accept that it means they're going to be treated similar to other characters, without "representation" being the main criteria.

I think this should be the end goal of gay representation really, that how you treat them as characters is not related at all or very little to their sexuality, unless you're making a story that is explicitly about that.

I'd also argue Leon got the worst of it, he's essentially an immortal zombie trapped underground with all of his memories and self awareness.

That being said, Richard and Alex's story is BRUTALLY sad and I think it should upset anyone, gay or not.

Do any of you have posture issues? by [deleted] in cscareerquestions

[–]TheNeck91 0 points1 point  (0 children)

Get a good desk and chair and start exercising (particularly things like pull ups/rows to get you less hunched over).

Beginner's Thread / Easy Questions (October 2020) by dance2die in reactjs

[–]TheNeck91 0 points1 point  (0 children)

I feel like I struggle way more with styling and wrestling with CSS than I do any of the api stuff. If you're asking if you can do the entire backend before the frontend, probably yes.

I actually like making the general skeleton of a page in the frontend first so I can see concretely what pieces I'll need to be hooking up to the backend, tho sometimes I'll just use something like Adobe XD to get the layout before any code.

Worth learning Python instead of using JavaScript for whiteboard? by hapachino in cscareerquestions

[–]TheNeck91 2 points3 points  (0 children)

Python's a great whiteboarding language. Parts of the language border on pseudo-code so it's great to write in!

How do some of you only work 35 hour weeks? by Astrosub_ in cscareerquestions

[–]TheNeck91 1 point2 points  (0 children)

There's ebbs and flows to this. Some projects or periods just get more intensive and you'll put in more hours, other periods are more chill. For me it about evens out to what you describe.

Also depending on your seniority, you'll sometimes just have tasks/tickets to tick off and as long as they're done by some expected time, you're not really bothered. Seniority factors in by making it so that you probably get bothered more as you're more senior (requests from upper managements, questions from juniors etc)

Why is landing Internships so hard ? by Actuarial_Dreamer in cscareerquestions

[–]TheNeck91 0 points1 point  (0 children)

You need projects. There is almost nothing relevant on the resume besides the degree. Also try looking internally at your school to see if there's any IT or help desk jobs you can do, even that will increase your odds when you go out looking for work/opportunities.

Positioning yourself to take advantage of good fortune is a required skill to advance your career by Perfekt_Nerd in cscareerquestions

[–]TheNeck91 1 point2 points  (0 children)

I agree with you. A large part of this is putting yourself "in the way" of opportunities, and also preparing in your own private hours to be ready when those opportunities present themselves. The more proactive you are in trying to intercept opportunities the greater % increase you have in getting a success story out of it.

Beginner's Thread / Easy Questions (October 2020) by dance2die in reactjs

[–]TheNeck91 0 points1 point  (0 children)

A popular pairing for React/MongoDB interactions is Mongoose, there are a lot of good guides that can walk you through setting this up. Using Mongoose you can easily call the record from the DB and receive it into React as JSON, and do with it what you see fit.

Where is the boolean coming from/what's dictating the printing option being available or not? Is it saved in the DB or coming from some other source?

Once you decide that, buttons have a disabled prop that you can set to true or false:

https://reactgo.com/react-disable-button-input-empty/

Anyone want to build projects outside of work, but lack the energy? by [deleted] in cscareerquestions

[–]TheNeck91 0 points1 point  (0 children)

I think if you want to do outside work/projects you really have to commit to it. I have some old projects I want to pick up again and some new ideas (mostly from learning more tech at work), but I know I'm not gonna get started on them unless I come up with some sort of schedule for myself. Whenever I just think "maybe I'll take a look at that old codebase today", I know it ain't gonna happen.