Image for post
Image for post

JavaScript has a nice Date Object. It can do all kinds of cool things like tell you the current date and time, etc. Lots of languages have a similar facility.

And you shouldn’t use it.

By that I mean, you shouldn’t use it directly.

Let me clarify a little bit. …


Image for post
Image for post

Angular 10 is out. Knowing all the newest features of a tool can be very important. So let’s break down what’s new in Angular 10:

Yeah, honestly, there’s really nothing new. Ok, there are a couple of tiny changes: Angular Material has a new date picker, and there’s some minor changes to things you almost for sure don’t use.

So does this mean that it’s a problem? Disappointing?

Nope. Why? Because first of all, upgrading to 10 will be super easy.

Also, this matches their release cadence. A new major version every 6 months, regardless of how many features make it in. …


Image for post
Image for post

There’s been some fascinating discussion and debate recently about the modern web, and whether what we often take for granted as “the right way to do things” is really better than “the old way”. A lot of this has been centered around Hey.com, the new email service that’s taking the world by storm.

Now if you’re wondering what is the “modern web” let’s use a pretty general definition. The modern web is a web app using some kind of front end framework — angular, react, vue, etc. …


Image for post
Image for post

I like to paint miniature figures for Star Wars (pics below for anyone who may be interested). It’s about the geekiest of hobbies. The other day I was on a website buying custom bases for these figures. This site was out of the US, and the default currency was not US Dollars, but there was an option to switch the currency to US dollars so I did, and then I noticed this:

Image for post
Image for post

Look closely. What’s going on here? That’s not US dollars. US dollars show the currency before the number, and it uses a point not a comma to separate the integer from the decimal portion of a number. And how did this happen? Long story short, the developers decided to use a minimal amount of JavaScript and manage currency conversion and formatting themselves. And unfortunately, localization, like so many issues, has a lot of nuances that aren’t obvious if you just learn a little. You have to dig deep and almost become an expert. A lot of currencies use commas and many use points, the placement of the symbol varies. …


Image for post
Image for post

In my free course on the Fundamentals of Angular, there are just over 2 hours of content on template-driven forms in Angular. One of the main parts of this is coverage of how to validate user input. This is an important part of any framework’s forms handling.

But in Angular, there’s a bit of an unmet promise when you learn about forms validation, and this can be confusing, so I’d like to just quickly cover the issue to help clear up any confusion you may encounter when doing forms validation in Angular.

When you first learn about forms validation, you quickly discover that there are several attributes you can add to an input control to validate that control. Angular’s integration with this validation is simple and effective. …


Image for post
Image for post

Dates in JavaScript and Angular can be dangerous if you don’t know what you’re doing. Let’s look at how to avoid potential bugs by gaining a fundamental understanding of JavaScript and Angular date handling and the quirks that come along with that.

To start off with, you need to understand the ISO date format that the JavaScript ecosystem supports. It’s actually the ISO 8601 format. It’s a fairly straightforward format that looks like this:

yyyy-mm-ddThh:mm:ssTZD

In this example we see that it is the year, month, and day separated by dashes, then a “T” and the time in hours, minutes, seconds, and finally a time zone. …


Image for post
Image for post

Earlier this year I was privileged to be able to help put on ng-conf Hardwired, a last-minute, seat of our pants scramble to turn an in-person conference into an online conference that was all duct tape and baling wire behind the scenes, but turned out great for the audience.

Anyway, I thought I’d just put out there that there were a few talks given at the conference that were truly epic and are absolute must-sees. These are pretty Angular-centric, FYI.

So here’s my list in no particular order:


Image for post
Image for post

In my free course on the Fundamentals of Angular, there are just over 2 hours of content on template-driven forms in Angular. One of the main parts of this is coverage of how to validate user input. This is an important part of any framework’s forms handling.

But in Angular, there’s a bit of an unmet promise when you learn about forms validation, and this can be confusing, so I’d like to just quickly cover the issue to help clear up any confusion you may encounter when doing forms validation in Angular.

When you first learn about forms validation, you quickly discover that there are several attributes you can add to an input control to validate that control. Angular’s integration with this validation is simple and effective. …


Image for post
Image for post

One of the most confusing things when building an Angular component is deciding what to put in the constructor and what to put in the ngOnInit method. Both of these methods are used for similar purposes, both fire once at the beginning of the life of a component, so knowing what to put where can be troublesome. In this article, we’ll break down when to use each method, and why, and what to put in them, and what NOT to put in them.

First, let’s break down what each method does, and when it’s fired.

The constructor is important in a component for two reasons. First, it’s a lifecycle method, meaning it is called when the component is constructed, so, therefore, it has an important purpose in that if you want specific code to run at a certain time (during construction) then this is the right place to do it. Second, it’s the place where you inject services into the component. …


Image for post
Image for post

Knowing the difference between arguments and parameters can be important.

But before we begin, just a quick note that our new course, Fundamentals of Angular, is out and completely free. That’s right. 100% free. Nothing behind a paywall. This isn’t a half course or anything. This is the whole enchilada. Go check it out.

And for a video version of this blog, click here.

I recently ran a quick little twitter poll to see if people, in general, knew the difference between parameters and arguments. The results of the poll were quite interesting.

Image for post
Image for post

Only 50% of people were confident with the difference between arguments and parameters, which makes this a good subject to review. …

About

Joe Eames

Mormon, Christian, Father, CEO of Thinkster.io, Organizer of @ngconf, @frameworksummit, React Conf. Front end developer, and Software Craftsmanship Evangelist.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store