[–] [S] 4 points 2 weeks ago

Waaaooww what a position

I'd want to disagree bc I know Nix and that feels declarative to me where as html just feels like actual drawing, like there's no conditional or iteration therefore how are you transforming information? HTML is a markup bc you need to render a UI and you don't know anything about the screen or keyboard&mouse so cope

  • source
  • parent
  • context
  • [–] [S] 3 points 2 weeks ago

    A bunch of weeks ago the CTO of my company calls me up to ask about my prejudice against the useState hook, I'm guessing I've just been giving my team too much shit in code reviews about them using useState hooks and they went to complain to him and he asked me to explain what the value of the useReducer hook was.

    His background is Java, Microsoft Java, C++, and not much else.

    So I was able to explain to him the value of the useReducer hook is a lot like the common class object. In useReducer you're expected to write discreet state mutations and the state could potentially have more than 1 primitive field that gets mutated, and that's just what object classes are! In an object class you're writing methods for mutating the underlying state, the reason I think most people don't feel like these two things are the same is because of the functional appearance of the reducer function and how in object classes you have the this as a variable just like any other, so you're not returning a new state.

    So just like in react where they're installing REDUX (like three generations of their families would be massacred if they didn't) just to write a switch case statement that puts the action in variables in the state. Bad programmers are just bad.

  • source
  • parent
  • context
  • [–] [S] 4 points 2 weeks ago

    I'm so heartbroken by the idea of unit tests. My first job was at a home automation startup and our primary product was a device that we would send ota firmware updates to. The device was based on an esp32, and because it received software updates from the app it had to be 100% robust and had full test coverage and the mono repo that would compile the firmware was gorgeous.

    I'm a web developer and I've been wanting to replicate that exact experience ever since but I just can't get any team on board. It's gone to the point where if the llm writes a unit test I'll just commit it so I don't care.

  • source
  • parent
  • context
  • [–] [S] 31 points 2 weeks ago (6 children)

    React works by maintaining a virtual representation of the DOM. When you dispatch state changes into the virtual DOM react can determine which components depend on the change and which side useEffects run.

    My gripe is that YouTube tutorials teach that the useState is the equivalent of a variable. This encourages average developers to problem solve solutions that end up using React's Virtual DOM for business logic. The YouTube tutorials have react devs planting 100s of useStates - some of which don't directly induce a visible-on-screen rerender - and then ⅒ as many useEffects to bind these states together. This means that for the Virtual DOM to come to the conclusion as to what html elements need to be changed and how it has already mutated 20-50-100s of times and the CTO tells me the react app is slow and they're mad.

    If 2 states have the opportunity to mutate each other back and forth then the truth is that you have 2 perspectives of the same state. And React gives you solutions for that - proper solutions - the useReducer hook is for defining these complex state mutations and the Context API for communicating that state to any component.

    And this has me quintuple pissed off because these same tutorial grade react devs install REDUX as compulsively as a pack-a-day smoker (that's #3). They use Redux to file variables in JavaScript memory (that's #4) like it's a global variable and rarely if ever use it for the complex state mutations they need instead I've seen react devs write components pull state out of redux into a component just so it can mount useEffect and process the state and dispatch the result back into redux. Let's not even bring up how the react-redux binding library literally uses the React Context API (that's #5).

  • source
  • parent
  • context
  • [–] 1 point 1 month ago

    Honestly sometimes I'm not even sure if I'm in a gay bar. I live in Bushwick and I'm told this is supposed to be the gay capital of Brooklyn and I don't see it, there are just !men all over the place.

  • source
  • What do you do for fun (programming.dev)
     

    Guys I'm in a slump, I keep having the same fight every time I feel bored and want to go out to do something and I can't because I don't know what to do because I don't even know what kinds of things I can do, like what classification of activity I should pick. And even when I do pick an activity class I'm paralyzed with the decisions regarding how to execute that activity. It's a 3dimentional puzzle of trying to find what doesn't make me miserable, is actually available to me, and I understand.

    Here is my current list of activity classes, I keep it as an Obsidian Kanban board where each lane is a my opinion. What classifications should I add or if you have any ideas for what specific things I can do I'd really appreciate that too.

    I'm based in Brooklyn


    New things

    • [ ] Hobbyist Groups Model Building, Gardening Clubs #social
    • [ ] Joining Environmental Groups #social

    Want to do

    • [ ] Volunteering at Charities #social #commitment
    • [ ] Calligraphy #lazy #equipment
    • [ ] Electronic Circuit Building #equipment #alone
    • [ ] Skating Inline, Ice #sport #inside #winter
    • [ ] Kickboxing #sport
    • [ ] Canoeing #sport #social #outside
    • [ ] Volleyball #sport #social #club #outside
    • [ ] Handmade Jewelry #equipment #class
    • [ ] Robotics #equipment #expensive #alone
    • [ ] Electronic Music Production #alone #class
    • [ ] Nature Walks for Relaxation #alone
    • [ ] Listening to Calming Music #alone
    • [ ] Progressive Muscle Relaxation #alone
    • [ ] Joining a Film Club #club
    • [ ] Community Art Classes #social #class
    • [ ] Collage Making #materials
    • [ ] Baking as a creative activity #lazy #home #materials
    • [ ] Music Composition #lazy
    • [ ] Sewing #art #equipment
    • [ ] Coffee Latte Art #class #equipment
    • [ ] Swimming

    Don't want to do

    • [ ] Volunteering for Political Causes #social
    • [ ] Participating in Dance Classes #social
    • [ ] Joining a Choir or Music Group #social
    • [ ] Language Exchange Clubs #social #club
    • [ ] Furniture Restoration #expensive #materials #resources
    • [ ] Garden Design #outside
    • [ ] Film Making #art #equipment
    • [ ] Rugby #sport #social #club
    • [ ] Lacrosse #sport #social #club #outside
    • [ ] Dodgeball #sport #social #club #outside
    • [ ] Ultimate Frisbee #sport #social #club #outside
    • [ ] Parkour #sport #social #outside
    • [ ] Wrestling #sport #social #club #inside
    • [ ] Surfing #sport #summer #outside
    • [ ] Snowboarding #sport #expensive #winter
    • [ ] Skiing Alpine or Cross-Country #sport #expensive #winter
    • [ ] Rowing #sport #social #club #outside #hard
    • [ ] Gymnastics #sport #social #club #inside #hard
    • [ ] Cricket #sport #social #club #outside
    • [ ] Basketball #sport #sport #social #club #outside
    • [ ] Football/Soccer #sport #social #club #outside
    • [ ] Weight Lifting #sport #club #hard
    • [ ] Rock Climbing #sport
    • [ ] Martial Arts Karate, Judo #sport
    • [ ] Dancing various styles #sport #club #social

    Planning

    • [ ] Volunteer at animal shelter
    • [ ] Pottery #art #expensive #equipment
    • [ ] Sculpting #art #expensive #equipment

    Doing

    • [ ] Reading manga #lazy

    Will do it again

    • [ ] Deep Breathing Exercises #alone
    • [ ] Boxing #sport #hard #club #equipment
    • [ ] Yoga #sport #inside #alone #club
    • [ ] Hiking #sport #outside
    • [ ] Swimming #sport #club
    • [ ] Spas #lazy #expensive
    • [ ] Writing Journaling, Novels, Poetry #art
    • [ ] Playing a Musical Instrument #art
    • [ ] Attending Networking Events #social
    • [ ] Aromatherapy #therapy
    • [ ] Massage Therapy
    • [ ] Herbal Therapy #therapy
    • [ ] Tea Ceremonies #alone
    • [ ] Mobile App Development
    • [ ] Open Source Contributions
    • [ ] Going to a comedy show #outside #lazy

    Did it once

    • [ ] Photography #art #equipment
    • [ ] Joining a Book Club #social
    • [ ] Cycling #sport #equipment #outside
    • [ ] Drawing #art #skilled
    • [ ] Painting #art #equipment
    • [ ] Scuba diving

    Do it with friends

    • [ ] Attending Community Festivals #social
    • [ ] Attending Concerts and Live Performances #social
    • [ ] Cooking Classes with Friends #social #class #club

    Hated it

    • [ ] Meditation #alone
    • [ ] Running #sport #outside #hard
    • [ ] Sitting in Silence

    Used to do it but its over

    • [ ] Gaming Communities Online or Offline #social
    • [ ] Tennis #sport #social #club #outside
     

    I just broke up with a friend of afew years.

    We met in college, she changed my life for the better, I'll never have a friend like that again.

    3ish years ago she moved to a different state, we haven't hung out in person in forever. We talk on whatsapp all the time. Recently she got into some trouble and asked me for help, I should have refused. Not like it would have made a difference, we haven't talked in weeks.

    I feel like I get "going through a hard time" better than everyone. Things suck right now but I have such a deep comprehension of how much worse-off I can be, I'm happy I'm not starving.

    But I still manage to reach out, I still manage to grow and change and do new things. Why can't she, why can't my friends stop being so broke-minded when it comes to me.

    Everything I want to do is 10x harder or 10x more expensive simply bc I suggest it but when others bring up the same ideas it's fine. How can it be impossible to manage in 10x difficulty when I do it all the time?

    I cannot be special, that's against the rule that everybody is special therefore nobody's special therefore I cannot be special. So how is it possible that I can feel so aweful all the time and still drag myself to go out and have fun even though I'm at a bar alone. I can do it. It's not hard. Just go out and get a drink and stand there and be ok.

    If you're feeling sad and a friend texts you then you have to text back, if you asked a friend for help and they helped you should owe them back atleast how hard it was for you to ask. You should have to give back something. And if you don't what does that mean for me? Do I gain the privilege to do something? Should I do something about it? What can be done?

    So I decided to break up with her because even if I didn't help she can go months without talking to me and that's the same as not having friends to me so what? Why is it different? Why shouldn't I make something out of this empty pipe between us and fill it with a push, people have pushed me out, does that mean that I get the privilege to push people out too? Should I (I already did)?

    All I know about making friends at my age is that the ROI is bad bc the cost is actually that daunting. The benefits have not increased since childhood but the difficulty has. And at some age I passed a threshold where the difficulty line rose above the benefit line and it's just going up and up and I can't stop it, I can't get ahead of it.

    I can't do anything but loose people. My last friend is married, she'll be having kids in afew years, she's on the other side of the planet. We're effectively not even friends anymore but what can I say about it? Tell her to slow down for me?

    I want community

    I want my old cat back

    I want to be a child again because I can't face an inevitable future where I know how much less I will have.

     

    A few weeks ago I was having a conversation with my therapist and he pointed some things that about me: mainly that my sense of socializing and bonding is feminine, I don't like making friends even though I like having friends I don't like the process of acquiring them, and because of that I don't really have many hobbies or much of a sense of self. My therapist explains to me that the average heterosexual male bonds with fellow males through shared experiences and activities like playing pool, we're doing construction.

    And then this got me reflecting on the whole concept of hookup culture. What if it's the average male that can only really bond with other men through shared experiences and activities like having sex? And my demisexuality makes me fundamentally incompatible with like 90% of all gay men, so on top of how hard romance is for me for other reasons, it is now 10 times harder?

    This is a hyper generalization I know but it's kind of bothering me that I have no one else to talk to about it.

    view more: ‹ prev next ›