Snippets

Quick bits and pieces that could save you a lifetime!

Undo git changes using the command line

January 08, 2019

Sometimes we have extra lines of code for testing that we don't want to commit and when we are done we should undo all the changes without manually going back to the IDE and reverting the changes…

VSCode - Insert a New Line at the End of Files Automagically

January 08, 2019

It's not about adding an extra newline at the end of a file, it's about not removing the newline that should be there. A text file, under unix, consists of a series of lines, each of which ends with a…

Fixing Webpack Error "Cannot find module WebpackOptions.json"

January 08, 2019

Using a tool with as many moving parts as webpack can come with its own headaches; mismatched versions of loaders, missing configurations etc. This error can happen often as a result of having…

Manual install APK to Android Emulator for faster builds.

January 08, 2019

Sometimes Android Studio can add a lot of overhead and you may want an easy way to generate an app's APK via the command line. Maybe you're using a CI and don't have Android studio installed, this…

Customize Storybook Using the Options Addon

January 07, 2019

Storybook is a great way to showcase your web components, and comes with many useful add-ons, among which is the options add-on which is a separate package on NPM that lets you customize using your…

Easily make REST calls in Android using Retrofit

January 07, 2019

For those who are new to Android Development, the first major complication is making a network call. If you look at the Android Developer Guide , you will immediately get confused with , and…

Send SMS Messages using Twilio's API in Javascript

January 06, 2019

Twilio is a popular platform for sending & receiving SMS/MMS messages. Twilio's easy to use APIs make on-demand messaging real fun! Before running the code below, fill in the values that are wrapped…

Search by