CodeNotes
Author

CodeNotes

Discuss code and AI, and document daily life and personal growth.

46
Articles
0
Likes
30
Views
0
Comments
Recent Articles

Latest from CodeNotes

46 recent articles
CodeNotes
CodeNotes
Jun 10, 2026 · Backend Development

After a Decade with Map, Are You Still Using containsKey + get + put?

The article reviews the seven Java 8 Map convenience APIs—getOrDefault, putIfAbsent, computeIfAbsent, computeIfPresent, compute, merge, and forEach—plus replaceAll and Map.of, showing concise code examples, best‑practice recommendations, concurrency considerations, and common pitfalls for modern Java developers.

APICollectionsConcurrency
0 likes · 10 min read
After a Decade with Map, Are You Still Using containsKey + get + put?
CodeNotes
CodeNotes
Jun 10, 2026 · Fundamentals

How Java 8’s Default and Static Interface Methods Transform Design Patterns

The article explains how Java 8 added default and static methods to interfaces—allowing method bodies, enabling backward‑compatible extensions, illustrating usage with code examples, handling multiple‑interface conflicts, and introducing Java 9 private methods, while summarizing common pitfalls and best‑practice guidelines.

JavaJava 8default method
0 likes · 9 min read
How Java 8’s Default and Static Interface Methods Transform Design Patterns
CodeNotes
CodeNotes
Jun 10, 2026 · Frontend Development

16 Practical CSS Tricks Using :has() to Replace JavaScript

The new CSS :has() selector finally lets parents be selected based on child states, eliminating dozens of lines of JavaScript; this article demonstrates sixteen real‑world use cases, explains compatibility across major browsers, and offers performance tips for safe adoption.

:has()CSS tricksFrontend
0 likes · 9 min read
16 Practical CSS Tricks Using :has() to Replace JavaScript
CodeNotes
CodeNotes
Jun 8, 2026 · Backend Development

Why Overriding equals Requires Overriding hashCode: An Interview‑Ready Guide

The article explains the contract between equals and hashCode in Java, shows what goes wrong when only one is overridden, demonstrates the correct implementation with Objects.equals and Objects.hash, covers IDE/Lombok generation, JPA entity nuances, inheritance pitfalls, records, and common anti‑patterns.

Best PracticesJPAJava
0 likes · 9 min read
Why Overriding equals Requires Overriding hashCode: An Interview‑Ready Guide
CodeNotes
CodeNotes
Jun 7, 2026 · Industry Insights

2026 Gaokao: Is Majoring in Computer Science or Software Engineering a Trap or the Right Path in the AI Era?

In the AI era, the article analyzes how AI reshapes computer science and software engineering majors, showing that low‑end coding jobs are being replaced while high‑end architecture and AI‑focused roles surge, and provides a tiered major ranking, score‑based recommendations, university selection criteria, and four‑year study pitfalls to guide 2026 Gaokao applicants.

Artificial IntelligenceCareer GuidanceComputer Science
0 likes · 10 min read
2026 Gaokao: Is Majoring in Computer Science or Software Engineering a Trap or the Right Path in the AI Era?
CodeNotes
CodeNotes
Jun 7, 2026 · Frontend Development

Which React Global State Library Wins? Redux, Zustand, MobX, or Context (3‑Minute Guide)

This article compares Redux Toolkit, Zustand, MobX, and React Context for global state management, offering a decision matrix, concrete code examples, practical tips, and scenario‑based recommendations so developers can choose the most suitable solution for their project's size, complexity, and team dynamics.

Context APIFrontend DevelopmentMobX
0 likes · 12 min read
Which React Global State Library Wins? Redux, Zustand, MobX, or Context (3‑Minute Guide)
CodeNotes
CodeNotes
Jun 7, 2026 · Fundamentals

Mastering Java Strings: When to Use equals vs == and Common Pitfalls

Java's String class is immutable and stored in a constant pool; the article explains the difference between == and equals, demonstrates common methods for inspection, transformation, splitting, and conversion, and shows best practices for concatenation with StringBuilder, thread‑safe StringBuffer, and newer utilities like join, repeat, format, and text blocks.

JavaJava 8String
0 likes · 10 min read
Mastering Java Strings: When to Use equals vs == and Common Pitfalls
CodeNotes
CodeNotes
Jun 6, 2026 · Frontend Development

9 Practical JSX Tips to Write Cleaner React Code

This article presents nine concise JSX techniques—such as using clsx for class concatenation, proper short‑circuit rendering, extracting deep ternaries, forwarding props with ...rest, leveraging children, memoizing style objects, correct comment syntax, fragment shorthand, and minimal boolean attributes—to boost code readability and component flexibility in React development.

FrontendJSXProps
0 likes · 7 min read
9 Practical JSX Tips to Write Cleaner React Code
CodeNotes
CodeNotes
Jun 5, 2026 · Backend Development

8 Essential Lombok Annotations to Slash Boilerplate in Spring Boot

This article walks through eight core Lombok annotations—@Data, @Getter/@Setter, @Builder, @AllArgsConstructor/@NoArgsConstructor, @Slf4j, @RequiredArgsConstructor, plus two optional ones—showing real‑world Spring Boot examples, common pitfalls, team conventions, and when to avoid Lombok.

AnnotationsBoilerplate ReductionBuilder
0 likes · 9 min read
8 Essential Lombok Annotations to Slash Boilerplate in Spring Boot