# DeveloPassion's Newsletter 8 - Bash Welcome to the 8th edition of DeveloPassion’s newsletter. Before we start, I’d like to ask all of you to **help me out a bit**. If you find this newsletter interesting, then please do take a bit of time to share to others on social media: With your help, others will also get a chance to discover and enjoy reading it. As an added benefit, it’ll also motivate me to continue the experience! Don’t forget that you can also follow me on [Twitter](https://medium.com/@dsebastien) and [Medium](https://medium.com/@dsebastien) where I currently publish my articles. ![[DeveloPassion's Newsletter Logo.png|DeveloPassion's Newsletter logo: lightbulb sprouting colorful idea nodes]] ## TypeScript news TypeScript 3.9 is here. Now we just have to be patient for all of our tooling/frameworks to support it. I’m currently stuck “because of” Angular, but it’ll support it real soon. As a matter of fact RC0 of Angular 10 is out: [https://github.com/angular/angular/blob/master/CHANGELOG.md#1000-rc0-2020-05-21](https://github.com/angular/angular/blob/master/CHANGELOG.md?utm_campaign=DeveloPassion%27s%20Newsletter&utm_medium=email&utm_source=Revue%20newsletter#1000-rc0-2020-05-21) While we’re at it, note that I’ve published an article about which features might come: LINK: [[What's new in TypeScript 4.0 - Language features (Article)]] Of course there aren’t that many certainties at this point, but at least a part of what I’ve explained in the article should be coming soon in TS land ;-) By the way, a while ago I’ve also published an article about type-only imports, which provide a clean solution to a little but annoying issue when you’re using types only as types and never as values. LINK: [[TypeScript type only imports and exports (Article)]] Why you should stop installing npm packages globally Today, I’ve published an article about why installing npm packages globally doesn’t make sense to me anymore. I have maybe 1-2 packages installed globally. For the rest, I rely solely on project dependencies and npx, which provide much better solutions. LINK: [[NPM best practices - Stop installing npm packages globally (Article)]] ## Keep Bash-ing Those who know me are certainly aware that I’m a big fan of Bash. I always have (at least) one terminal open, ready to serve me. LINK: [[Discover Bash aliases and understand why those are great (Article)]] As a scripting language, Bash isn’t that great and it’s not really the part I love the most. I like it for its ubiquity, but the syntax is really painful. Compared to Bash, PowerShell just feels soooo much cleaner. Having been a Windows sysadmin for a while and having a programming background, I really digged into it and could see how powerful it is. But I’ll write about PowerShell another day ^^. No, what I enjoy most about Bash is not really the scripting. It’s rather its support for aliases and functions, which I really use all the time. I wrote an article about this, highlighting some of the cool things that one can do with Bash (or Fish, or zsh :p). ## Git concepts series I think that many Git users stick to the real basics because they don’t truly understand the core concepts. Using Git without understanding it clearly (I don’t mean the internals :p) is really sad. Git is a tremendously powerful tool but, as with anything else, it requires quite a bit of time to really master it. There are already quite a lot of great tutorials/courses about Git, but I wanted to have a go at explaining it. This is why I’ve started writing a series about Git concepts. So far, I’ve published two articles. The first one explains what it means for Git to be a distributed version control system. The second one explains the different areas to be aware of when using Git: the working tree, the index and the repository. Over the next couple of weeks, I’ll continue this series, progressively going from basic concepts like branches and commits to more advanced ones like remotes, fetch, merge, rebase, etc. I hope that these articles will prove useful to some people! :) LINKS: - [[Git tutorial for beginners Part 1 - What is a DVCS (Article)]] - [[Git tutorial for beginners Part 2 - Git repository, working tree and staging area (Article)]] ## Angular route vs scrolling Out of the box, Angular’s router provides support for handling scrolling automatically when navigating from route to route, whether via routerLink, back/forward Web browser buttons or otherwise. Unfortunately, that support isn’t all that great. In my current project, I’ve had to spend a whole evening hacking around to make it work as I wanted. I took the opportunity to share my solution and explain it in the following article: LINK: [[Angular Tips - Understand Angular scroll position and ScrollPositionRestoration (Article)]] What I did is create an Angular service that keeps track of the scroll position so that it can be properly restored when navigating. But I went a tad further and added support for defining the scroll behavior through route data. Thanks to that, I can now easily define how the scrollbar should react (or not) when navigating to specific routes. This solution ain’t perfect, but it is at least clean and functional. Hopefully Angular will provide a better solution for this in the future! LINK: - [[Configuring sourcemaps with the Angular CLI (Article)]] - https://www.dsebastien.net/2019-07-24-configuring-sourcemaps-with-the-angular-cli// LINK: - [[How to create a custom Angular Webpack configuration (Article)]] - https://www.dsebastien.net/2020-06-14-customizing-your-angular-apps-webpack-configuration// LINK: - [[Angular Template Type Checking (Article)]] - https://www.dsebastien.net/2020-06-16-angular-template-type-checking// LINK: - [[Knowii Community]] - https://www.store.dsebastien.net//product/knowii-community