The web is full of articles praising the improvements of Angular 6, such as library support (great!) and Angular Elements (even greater!). One small change usually passes by as a mere side-remark. But it’s a useful change, too. Angular 6 now officially supports TypeScript 2.7. That, in turn, is a major step forward for our […]
When someone like Brian Goetz is giving a talk, it’s almost always worth listening. His talks at the 2018 JAX in Mainz, Germany, were no exception. There was an idea resonating particularly well with me, so let me paraphrase this part of Brian’s talk. Or rather, what I made of it: I didn’t take a […]
Since version 2.0, Angular uses RX.js observables a lot. Such an observable is potentially infinite. So in many cases, you need to unsubscribe from the observable manually. If you forget to do so, you end up with a memory leak. Actually, you’ll probably get away without unsubscribing for a long time. First, Angular cares about […]
Bootstrap claims to be a “mobile first” framework. However, judging from the breakpoints, it’s a mobile-only layout framework. The largest breakpoint is 1200 pixels wide. Even my 15” MacBook has much more screen estate: its screen is 1440 pixels wide. Many desktop monitors have a width of 1920 pixels, and 4k monitors are gaining popularity […]
Anybody ordered a new JVM compiler? Whoever ordered it – now it’s there, and it’s exciting! But wait: is it a compiler? No, it’s not. It’s more. Currently, it’s half a dozen compilers, plus a framework making it easy to write your own compiler. In a nutshell, this is what the Graal project promises: It’s […]
Java 10 is there! And the most controversial feature of it is the var keyword. Should you embrace it or not? If you’re a regular reader of BeyondJava.net, you probably know that I already propagated the var keywords years ago. But I’m spending enough business hours each day with Java to know how Java programmers […]
Like countless other developers, I decided to monkey-patch console.log to implement the logger of our Angular application. You may or may not like this approach, but it worked flawlessly. The first time it broke was when we deployed it to production today. What had happened?
Monkey patching is modifying a third-party class. It’s a great tool, coming in handy all the time. Only it’s frowned upon by the experienced programmers. Should you adopt or abandon monkey patching? Let’s have a look at some useful applications of monkey patching first.
One of the first feature requests of TypeScript was the Elvis operator. More precisely, the null-safe navigation operator. That’s a variant of the “dot” operator allowing you to access attributes and methods even if the object preceding the dot is null or undefined. In most languages implementing the Elvis operator, the expression null.firstName simply returns […]
When I teach Angular, I keep telling my students that Angular components are custom HTML elements, while Angular directives are custom attributes. Every tutorial I know teaches the same. Nonetheless, Angular is much more flexible. In reality, the selector of both components and directives can be any CSS selector. For instance, you are allowed to […]
Common wisdom says that Java runs on bytecode. Most developers also know there’s something like a JIT compiler, but few developers are aware that the JIT compiler generates real machine code. Let alone that we can see it.
npm doesn’t like to be fenced in by a corporate firewall. Too bad most npm installations live precisely there. The other day, I ran an npm install on the customer’s PC. The same command that finishes in 40 seconds on my machine took roughly a quarter of an hour. Plus several hours of troubleshooting. It […]
Isn’t it funny that I start writing a series of articles about Java 8 Lambdas in 2018? Mind you: my first article dates back to April 2012, six years ago. I fell in love with functional programming even earlier. I suppose it was roughly in 2008, ten years ago. From this perspective, functional programming is […]
Functional programming is en vogue. There are many good reasons to adopt functional programming. Recently, I watch more and more Java programmers using the new programming style. As things go, they experiment and play with their new toy, pushing it to the limits. This article briefly shows why Lambdas are useful, what Java programmers make […]
Spectre and Meltdown came as a shock. They showed that low-level CPU optimizations have an impact on our lives. Plus, they proved an illusion of most programmers wrong. Yes, you’re using a high-level language. But that doesn’t mean all those abstraction layers shield you completely from the CPU. I’ve demonstrated the effect of the CPU […]
They announced Vue.js to me saying “It’s like Angular, only they did it right this time”. I don’t think there’s anything wrong with Angular, so my curiosity was piqued, and the stakes were high. What does Vue.js better than Angular? So I spend two afternoons playing around with Vue.js. First impressions Before starting to dig […]
After a long search, I’ve finally found two good libraries bringing the design language of Material Design to Bootstrap. Actually, I’ve seen similar attempts before. Just think of the Paper theme bundled with BootsFaces. It’s not bad, but I wasn’t too excited when I saw it. I didn’t run a comprehensive test yet, but at […]