1. Remove duplicates value from an array const languages = ['java', 'php', 'ruby', 'python', 'php', 'python']; console.log(languages); // First method const uniqueLangs = Array.from(new Set(langua...
Useful Docker & docker-compose commands
Docker Commonly used Docker commands Command Description docker version Show the docker version docker image ls or docker images ...
Escape the underscore and the percent when searching by like, ilike expressions in PostgreSQL
To escape the underscore and the percent to be used in a pattern in like expressions use the escape character (\): SELECT * FROM users WHERE name LIKE '\_'; SELECT * FROM users WHERE name LIKE '\%'...
What's the meaning of /gi in a regex?
g modifier: global. All matches (don't return on first match) i modifier: insensitive. Case insensitive match (ignores case of [a-zA-Z]) In your case though i is immaterial as you don’t capture ...
Jekyll Chirpy Text and Typography
Titles H1 - heading H2 - heading H3 - heading H4 - heading Paragraph I wandered lonely as a cloud That floats on high o’er vales and hills, When all at once I saw a crowd, A host, of g...
Javascript Keycode Enums
var enums = {}; enums.keyboard = { BACKSPACE: 8, TAB: 9, ENTER: 13, SHIFT: 16, CTRL: 17, ALT: 18, PAUSE: 19, CAPS_LOCK: 20, ESCAPE: 27, S...