Node.js Tutorials
How to Use window.crypto in Node.js
I've been writing a bunch of jest tests recently for libraries that use the underlying
window.crypto
methods likegetRandomValues()
andwindow.crypto.subtle
key management methods. One problem I run into is that thewindow.crypto
object isn't available, so I need to shim it.To use thewindow.crypto
...Command Line trash
One of the first commands you learn when experimenting with command line is
rm
, the utility for deleting files and directories. Deletion is a core computer UI operation but operating systems use a "Trash" paradigm, where files are stored before truly deleted. With the...Set a Default Node Version with nvm
As I've shown you in the past,
nvm
an excellent utility for switching between Node.js versions. Whether your host machine or CI, building and testing your apps on different Node versions is a necessity. I've recently found a fewnvm
commands that I found really...Simple Node.js Proxy
When I wanted to refresh my React.js skills, I quickly moved to create a dashboard of cryptocurrencies, their prices, and and other aspects of digital value. Getting rolling with React.js is a breeze --
create-react-app {name}
and you're off and running. Getting the API...How to Create a QR Code
QR codes aren't everyone's cup of tea but I quite like them. If I see something I want to remember or check out later, especially when on the road, it's super easy to take a quick picture -- it's much easier than trying to remember a...
How to Not Minify Source with webpack
The webpack JavaScript utility has taken over the modern JavaScript landscape, so much so that it's hard to be a JavaScript developer and not use it. JavaScript build utilities are the point where they do best practices implicitly, like minify code, caching, and more.I was...
Stop Installing Packages Globally
These days, most front-end projects are going to involve NPM packages of some kind. Occasionally, when browsing documentation for these packages, I’ll see a recommendation to install a package like this.Or like this.In both of these examples, the package is installed globally. This means you can...
How to Detect Text in Images
Images are a great way to communicate without text but oftentimes images are used/abused to spread text within social media and advertisements. Text in images also presents an accessibility issue. The truth is that it's important, for any number of reasons, to be able to detect...
Convert HTML to Markdown
One of my biggest mistakes with this blog was not finding a WordPress plugin that would allow me to write my posts with markdown; to this day I still need to write posts in "Visual" mode and then manually convert the post to HTML for "Text"...
How to Create a Twitter Bot with Node.js
Twitter bots have been in the news over the past few years due to election meddling, not only in the United States but stretching across the globe. There are, however, good and logical reasons for creating Twitter bots. In order to see how easy it was...