Shovon Hasan - Blog
  • Home

Shovon Hasan

Queens, New York •
11 posts •
Easily fixing security vulnerabilities in transitive dependencies with Yarn.

Easily fixing security vulnerabilities in transitive dependencies with Yarn.

It's 4:30 on a Friday and GitHub hits you with one of these: How do you make this go away and still get home on time? If GitHub's automated security fixes feels

  • Shovon Hasan
1 min read
Writing Type-safe Defaults with TypeScript's Pick Type

Writing Type-safe Defaults with TypeScript's Pick Type

A common pattern I use when writing TypeScript applications is creating default objects and overwriting some or all of those defaults with data provided by the user. But there's a common mistake when

  • Shovon Hasan
2 min read
Using Absolute Imports with Jest in Create React App

Using Absolute Imports with Jest in Create React App

Jest's modulePaths option makes it possible.

  • Shovon Hasan
1 min read
Using Promises with FileReader

Using Promises with FileReader

Using `await` to handle FileReader's asynchronicity can be a lot simpler than dealing with events.

  • Shovon Hasan
1 min read
Pattern for Rendering Lists of Connected Components with React-Redux

Pattern for Rendering Lists of Connected Components with React-Redux

The key is in the second argument of your `mapStateToProps` function.

  • Shovon Hasan
4 min read
Deploying a TypeScript + Node AWS Lambda Function with Serverless

Deploying a TypeScript + Node AWS Lambda Function with Serverless

Serverless plugins make developing Lambda apps with TypeScript painless (no webpack required!) This guide assumes you have TypeScript and Node installed as well as an AWS account. We'll be using serverless to set

  • Shovon Hasan
4 min read
Time & Space Complexity of Array.sort in V8

Time & Space Complexity of Array.sort in V8

If you've ever looked at the syntax for sorting an array in JavaScript, you may have wondered how it works under the hood. The ECMAScript Spec is (intentionally, I would guess) vague about

  • Shovon Hasan
2 min read
Greedy Solution to an Array Balancing Problem

Greedy Solution to an Array Balancing Problem

A few weeks ago on reddit I read a question that asked for a solution to a fairly simple looking array balancing problem. But it turns out that a satisfactory solution isn't easy

  • Shovon Hasan
3 min read
Never Use Array.from() to Convert Strings to Arrays

Never Use Array.from() to Convert Strings to Arrays

TL;DR: Splitting a string into an array is about 70 times faster with 'a string'.split('') than Array.from('a string'). In my interview prep I came across an article on

  • Shovon Hasan
3 min read
Simulating an Ability from World of Warcraft in JavaScript

Simulating an Ability from World of Warcraft in JavaScript

After working through Gordon Zhu's fantastic "Practical JavaScript" course, I wanted to make an app to put my newfound knowledge to the test. I like World of Warcraft, and I play

  • Shovon Hasan
5 min read
The First Step

The First Step

It seems natural to me that the first post on my programming blog should be how I got the blog up and running. I started with a clear vision in mind: I wanted

  • Shovon Hasan
5 min read
Shovon Hasan - Blog © 2023
Latest Posts Twitter Ghost