Angular 2+ is here

Angular 2+ Is Here

During the last month's I've been really busy so I haven't had much time to post anything, but I have used new frameworks and languages in my projects. First of all, I started working on a new version of the PASmedia web app in Angular 2 (now just Angular because of Angular 4 and much more to come) and Typescript. I've really enjoyed the development process for Angular 2+ apps, it is much easier to keep code organized, prevent bugs and write cleaner code. To develop Angular apps I've been using Visual Studio Code, a code editor that has Typescript support, and Angular CLI in Bash on Ubuntu on Windows (yeah, I know, confusing naming) also called WSL (Windows Subsystem for Linux) a really powerful tool for development in Windows. WSL had some flaws but after the Creators Update it became more useful and less buggy, you can even run full Ubuntu apps with GUI on it with some third party tools.

I really like the Typescript approach, because it helps you to write cleaner code because of its structure. Typescript has something called strong types, this strong types and other features help your text editor/IDE warn you of errors before compiling (and during compilation) the project so it makes app development a bit less bug-prone.

Angular has a really good router solution included. It lets you specify different routes and child routes for your app, each one using its own component. The router allows you to add dynamic routes, this can be used when you need to fetch data from a database depending on the requested route, for example, so in here :id can be any blog post id. This is just one of many other first-party modules.

Now Angular has a CLI. This CLI helps you start a project, create a new component or service in your project, serve your project for testing, and compile your project amongst other features. This makes using Angular a lot more developer friendly. The build command is really neat because it compiles all your different .ts files and modules into some bundled and compressed .js files.

In this Angular app, I used Firebase, a real-time database service owned by Google. They give me a sign in system, hosting, SSL certificate, cloud functions, and a real-time database for free (because of my project's size). Firebase has an Angular 2 module that's still in development but comes in handy when developing Angular apps with Firebase.

About a month ago I deployed PASmedia 2.0 (it's a private site, so there is no link to see it :( ) and I'm overall really happy with the Angular development experience and I would definitely recommend it to you if you need to develop a web app. The only drawback it has is that because it's so new there's a limited amount of available modules.