Migrate is a very useful migration framework for Node. Unfortunately, its documentation is lacking in places. Here are a couple of handy options not covered by the README.
sudo -u <user> <command> doesn't inherit the user's environment. Here's how to fix that.
Type guards let you provide TypeScript with more information about a variable's type. Type guards are especially useful when working with a variable which may be
Chai lets you assert that some code throws an error. The key is to pass the test subject to
expect, not the test result.
You can disable ESLint for a single line, a block of code, or an entire file. Wherever possible, specify the rule or rules you wish to disable.
Don't use "deep equals" when comparing arrays with Chai; it depends on element order. Examine the array members instead.
How to find documents according to the size of an array field.
TypeScript's strict type checking can cause problems when working with numeric environment variables. Here's a solution.
VS Code has the concept of code actions. When a code action is available, VS Code displays a small lightbulb icon nearby 💡. Clicking on the lightbulb displays a list of available actions.
bravo. We need to determine which items appear in
alpha, but not in