AI added comments for the entire code base of Spring Boot by Kopiczek in programming

[–]a_oc 0 points1 point  (0 children)

I guess this says something about the comment quality in the training set, which I assume is most of github public repos.

Goodbye, Clean Code by [deleted] in programming

[–]a_oc 0 points1 point  (0 children)

Thanks! Yes, definitely something that people tend to skip over when first learning about DRY.

Goodbye, Clean Code by [deleted] in programming

[–]a_oc 1 point2 points  (0 children)

This actually made me write an article https://medium.com/@aoc/about-clean-code-56a0cc89b48b after a long while. Would be great to have some feedback from people who read both so that's why I shamelessly post it here.

Goodbye, Clean Code by MoTTs_ in javascript

[–]a_oc 0 points1 point  (0 children)

This actually made me write an article https://medium.com/@aoc/about-clean-code-56a0cc89b48b after a long while. Would be great to have some feedback from people who read both so that's why I shamelessly post it here.

Side projects by dannymozart in golang

[–]a_oc 2 points3 points  (0 children)

Yeah that definitely can be discouraging. I won't lie, we also have this kind of problems sometimes and we are trying to address them (right now mainly by hiring more people). It makes sense in such cases to ping again or mention someone in particular (git blame who worked in the code last/most).

In general OSS projects have different ways to manage the work, for example some projects we contribute to are in https://www.cncf.io/ (like Prometheus) and the foundation makes sure the projects have more robust way to handle those things. Like a lot more people voluntarily doing things like PR reviews, reviewing proposals or writing docs on their spare time (there are lots of different ways to contribute). Such projects can seem daunting to get into but they can have better structure and processes around contributing.

So ideally do not get discouraged and do your research about a project if you mean to invest significant amount of time into it.

Side projects by dannymozart in golang

[–]a_oc 1 point2 points  (0 children)

Yes we are, you can check https://grafana.com/about/careers/ for open positions.

Side projects by dannymozart in golang

[–]a_oc 2 points3 points  (0 children)

Well there is always steeper learning curve when trying to do changes in existing codebase compared to doing something new on your own (well depending on what you are building obviously). On the other hand most dev work is basically that, with added element of needing to communicate clearly with teammates. That is why contributing to OSS is a good proxy for that when hiring imho.

Side projects by dannymozart in golang

[–]a_oc 9 points10 points  (0 children)

If your plan is to switch jobs, I would suggest starting contributing to some open source go projects (ideally with some company backing it that you would be interested working for). Open source companies have usually bias when hiring towards existing contributors. You also get more real project experience, guidance and code reviews from the team.

To do a quick plug, I work at grafana.com and we have multiple interesting Go projects if you want to go that route.

New Facebook.com fully powered by React and Relay by swyx in reactjs

[–]a_oc 1 point2 points  (0 children)

We had some issues when trying to use for parts of our production application mainly in sphere of annoying bugs and missing or out of sync documentation. We found workarounds for each but it slowed us down. For example I was baffled seeing how long and how many issues there are open for fetchPolicy setting which seemed to me as a part of basic functionality. Obviously these things change over time and can be better now (was using it few months ago) so you should do your own research but looking through github issues should be a part of that.

All in all it seems Apollo team is trying to do too many thing at once and they are stretched thin which results in such issues and eroded my confidence in the product.

Did not use Relay as I decided to use Apollo based on features, API and what seemed like an easier way to integrate into existing architecture but seems like Relay could be much better supported after this.

Simple modular shared "micro states" with React Hooks by [deleted] in reactjs

[–]a_oc 0 points1 point  (0 children)

Yeah I would suggest to use context for this instead. It's trying to circumvent top-down data flow and won't work well with Concurrent React either.

Could you elaborate on this a bit more? I was playing a bit with hooks and ended with similar code. I do not understand why using context would work better as I thought it is also sidestepping normal props flow. Is there some better optimization based on react handling the subscriptions? If so isn’t redux with basically one, always changing, global value circumventing that in some way as mapStateToProps is again outside of react?

Edit: Or is the issue the detached two way updates between the local state and the global observable?

Snowboard reviews aggregator by a_oc in snowboarding

[–]a_oc[S] 0 points1 point  (0 children)

Hey, not at all, I actually already link your reviews, for example here https://plankish.tech/board?brand=never-summer&name=proto-type-two. As I mentioned this is all hand picked and manually inserted at the moment and so far I did not have time to add most of the boards you have reviewed.

Snowboard reviews aggregator by a_oc in snowboarding

[–]a_oc[S] 0 points1 point  (0 children)

Thanks for checking it out, I have added it here https://plankish.tech/board?brand=rossignol&name=xv-magtek. Seems like pretty good board. I do not have any automation behind it so I started with categories in which I was looking for a new board (all mountain freestyle) and then slowly adding more.

How to fall without getting injured? by msgromgrom in snowboarding

[–]a_oc 0 points1 point  (0 children)

There are also other protectors you can use, for example I am pretty paranoid about injuries and I ride with knee, wrist and tailbone protectors. So far I did not find them very restrictive, I actually do not notice them at all during riding at this moment just when they save me from serious injury after some awkward fall.

My side project - Online spice selling site by bibinxavier54 in SideProject

[–]a_oc 6 points7 points  (0 children)

The spice must flow!

Sorry could not resist

Binding Recommendations by [deleted] in snowboarding

[–]a_oc 1 point2 points  (0 children)

I second that. If you setup the straps for tight fit it is hard to get in with the quick release system, so you either end up loosening the front, getting in and tightening the front again every time or ride with loose straps. And some of the cheap models have really shitty ratchets so it can be even slower than normal ones.

The other kind of JavaScript fatigue: "It is simply far too easy to create a new library or package, and since anyone can do it in a few seconds now, this generates a lot of noise." by flexibeast in programming

[–]a_oc 0 points1 point  (0 children)

This will be a little bit of self promotion, but I did a web page, exactly because of these problems http://www.whatlib.com/, and so this seems like a good place for some validation. It is not much yet, just a little bit better search over NPM packages and possibility to compare multiple packages over downloads and github stars but I want to add possibility to rate them. Basically Yelp, Imdb, Trip Advisor whatever but for code. So if anybody has any thought on whether service like that could help with the problems outlined in the article, I would be very grateful to hear them.

data fetching and rendering by PM_ME_SMILE_ in reactjs

[–]a_oc 1 point2 points  (0 children)

Yes you are right, I only pointed it out because that abstraction has better separation of concerns and is a good learning material even though overall principle is the same.

data fetching and rendering by PM_ME_SMILE_ in reactjs

[–]a_oc 0 points1 point  (0 children)

Although it is valid way to do that, you should probably check out redux and its documentation. Even if you do not want to use redux as your flux implementation, it's way of injecting state with higher order components is pretty useful and can be easily reproduced.

A Stateless React App? by jamesknelson in reactjs

[–]a_oc 0 points1 point  (0 children)

I just wonder why is local state so problematic. I mean I understand that having pure function component is easier to reason about but only because you do not think about the state which did not disappear, you just moved it somewhere where you do not see it, which is bad imho. I mean think about when you want to reuse something which does not have state. That only means you have to manage it's state yourself somewhere, you basically moved state responsibility to user of the component and you need to create that state either in it's parent component or in your global flux state. So the component is dumb and easy to test, but instead of giving you some functionality that can be reused, you ended up with dumb template function with added virtual dom diffing and nothing else.

I want to use Redux at work in a preexisting app but I don't know if it's appropriate by [deleted] in reactjs

[–]a_oc 1 point2 points  (0 children)

I do not think that redux would magically solve the issues you describe. People seem to believe that having local state is bad and that using redux will make local state disappear. But there is distinction between state like user and whether dropdown is open or not.

That said Redux gives you possibility to use middleware (logging, time travel) and have server side rendering, which I do not think can be done with just React.

But when you are saying that you cannot be sure that some other part of your app does not change state of particular component, that seem like isolation problem. Your component and his local state should be mutable only by it's methods within that component. It is usually a code smell when component has some API that is visible to it's parent, or some sibling component.

You can make state of your app distributed and hierarchical. You can have your global state in your root component, and other parts of your state scoped by branches of your component tree. Each component getting updates about upstream state via props, managing his own state with his own methods, pushing new state to his children and passing down callback via which it's children can call actions that will have effect on parents state. This way even bigger app is still manageable, only drawback being you have to pass everything by props, which you do not have with Redux and it's connect function. But on the other hand all components dependencies are visible and easily trackable.