7±2 Reasons Psychology Will Help You Write Better Code by Moran Weber

  Рет қаралды 5,430

JSConf

JSConf

Жыл бұрын

During the Cold War, the CIA knew how to expose Russian spies disguised as American citizens with 100% certainty. They used only a piece of paper and a few questions. How did they do that? Hacking your mind is easier than you think. Let’s explore how these mental hacks affect the code we all read and write. We’ll take a stroll through the world of cognitive psychology, and shed some light on some of our industry’s best and worst practices. We’ll have a few interactive examples of our mind’s limitations, examine how these limitations manifest themselves in real code samples and engineering practices, and take away scientifically backed techniques on how to write better code.
jsconfbp.com/speakers/moran-w...
About Moran
Moran Weber is the CEO & Founder of Women on Stage; a platform to showcase, book, and train women professional speakers for any tech event, conference, meetup, or webinar (www.womenonstage.net/). She’s formerly Tech Lead at Wix with 11 years of experience in software development, and also a Social Psychologist, holding an MA in Social Psychology, along with a BSc in Computer Science and Psychology from Tel-Aviv University. Moran used to have major stage fright and impostor syndrome but after she overcame her anxieties and became a public speaker herself, she decided to go on a mission to amplify women’s voices everywhere.

Пікірлер: 10
@tvanantwerp
@tvanantwerp Жыл бұрын
I disagree with the idea of a cold code review. I absolutely don't want to start reviewing a PR without any context what the person was trying to do-it would dramatically increase the time it take to understand what they've written, and with very minimal benefit. The marginal gain of figuring out their code from scratch usually isn't worth the extra time and effort.
@jack19820814
@jack19820814 Жыл бұрын
I totally agree.
@23stoir
@23stoir Жыл бұрын
I think you got her wrong there. What she meant imho is that you should state WHAT you wanted to do with your code (i.e. intention) but not explain HOW you did it. Best example would be a feature commit - what was implemented. You wouldn't expect to read how that was achieved in the commit messag, right?
@womenonstage3465
@womenonstage3465 Жыл бұрын
Hey @Tom VanAntwerp, I'm the speaker. You didn't understand my intention here (see what I did here?). As @23stoir mentioned, the point is when you ask for a CR, you shouldn't start explaining your implementation and the architecture ("HOW"), or anything that wouldn't be clear when you're not around anymore to explain it verbally (when you leave the company or on sick leave for instance). You SHOULD definitely write a commit message that directs to the ticket of the feature + any other context about the business logic ("WHAT"). For the case of doing something that's not so clear on a first glance (for example fixing weird platform bugs or stuff like that), then your commit message should explain WHY you did that as well. The point is that if the purpose is making sure the next developer will understand what's written there, then they should track it on their own by annotating and reading it (and then we know it's readable)
Жыл бұрын
First iteration of code review is cold. When you eliminate obvious mistakes, you can check if code is meeting the requirements - then you can take all information that you need to understand what code should be doing.
@hwthwt9951
@hwthwt9951 Жыл бұрын
Wish she went into more detail about the cold code review. Does that mean we should not be writing detailed commit messages? Or should I just start the CR first without reading the commit?
@23stoir
@23stoir Жыл бұрын
Best example would be a feature commit - what was implemented. You wouldn't expect to read how that was achieved in the commit messag, right? So just explain WHAT you achieved (intention) not HOW you did that in your code..
@hwthwt9951
@hwthwt9951 Жыл бұрын
@@23stoir I disagree. The commit should be a brief summary of the implementation details. The ticket the commit refers to should be for business specs.
@womenonstage3465
@womenonstage3465 Жыл бұрын
Hey @@hwthwt9951, I'm the speaker. As @23stoir mentioned, the point is when you ask for a CR, you shouldn't start explaining your implementation and the architecture ("HOW"), or anything that wouldn't be clear when you're not around anymore to explain it verbally (when you leave the company or on sick leave for instance). You SHOULD definitely write a commit message that directs to the ticket of the feature + any other context about the business logic ("WHAT"). For the case of doing something that's not so clear on a first glance (for example fixing weird platform bugs or stuff like that), then your commit message should explain WHY you did that as well. The point is that if the purpose is making sure the next developer will understand what's written there, then they should track it on their own by annotating and reading it (and then we know it's readable)
@mdsafikulislam9113
@mdsafikulislam9113 Жыл бұрын
💬🌷
How Senior Programmers ACTUALLY Write Code
13:37
Healthy Software Developer
Рет қаралды 1,3 МЛН
Balloon Pop Racing Is INTENSE!!!
01:00
A4
Рет қаралды 16 МЛН
Normal vs Smokers !! 😱😱😱
00:12
Tibo InShape
Рет қаралды 58 МЛН
How To Choose Ramen Date Night 🍜
00:58
Jojo Sim
Рет қаралды 53 МЛН
Testing Web Accessibility by Adrián Bolonio
30:25
JSConf
Рет қаралды 4,8 М.
Learn SOLID Principles with CLEAN CODE Examples
28:35
Amigoscode
Рет қаралды 256 М.
🚀  TDD, Where Did It All Go Wrong (Ian Cooper)
1:03:55
DevTernity Conference
Рет қаралды 546 М.
Building Resilient Frontend Architecture • Monica Lent • GOTO 2019
33:46
The Art of Code - Dylan Beattie
1:00:49
NDC Conferences
Рет қаралды 4,7 МЛН
This is the Only Right Way to Write React clean-code - SOLID
18:23
Пленка или защитное стекло: что лучше?
0:52
Слава 100пудово!
Рет қаралды 1,8 МЛН
Готовый миниПК от Intel (но от китайцев)
36:25
Ремонтяш
Рет қаралды 385 М.
Наушники Ой🤣
0:26
Listen_pods
Рет қаралды 495 М.
Wow AirPods
0:17
ARGEN
Рет қаралды 532 М.
Наушники Ой🤣
0:26
Listen_pods
Рет қаралды 495 М.
M4 iPad Pro Impressions: Well This is Awkward
12:51
Marques Brownlee
Рет қаралды 6 МЛН
Best Gun Stock for VR gaming. #vr #vrgaming  #glistco
0:15
Glistco
Рет қаралды 4,9 МЛН