On , I served my final day at Piktochart. I spent 4 years and some change at the company, joining as a JavaScript intern and leaving a DevOp & backend engineer for Piktostory. Piktochart was my first “real” job and having spent a good part of …
javascript ∈ article.tags
-
-
how to use a valid email when signing up for Sephora
Please don't take anything in this article seriously.
Gmail, Outlook, and Yahoo! Mail are popular options for creating incredible email addresses that will be compliant with most software and are allowed to bypass sophisticated spam filters as the following:
<?php if (endsWith($sender, "gmail.com") || endsWith($sender, 'yahoo.com') || endsWith …
-
setTimeout and setInterval in gjs
The GLib.timeout_add function is the GJS equivalent to both
setTimeout
andsetInterval
. It calls a given function repeatedly (such asfunc
) at given intervals until it returns a falsy value. It returns a GLib Source id, which just likeclearTimeout
orclearInterval
can be removed with the static GLib … -
generating video thumbnails in js
HTMLCanvasElements are amazing for all kinds of things. Paired with the CanvasRenderingContext2D's drawImage method, generating video thumbnails on browsers are incredibly easy. The interface for the method is as follows:
void ctx.drawImage(image, dx, dy); void ctx.drawImage(image, dx, dy, dWidth, dHeight); void ctx.drawImage(image …
-
the error paradigm
The error programming paradigm comes from the recognition that errors are expected. Consider a function that is meant to parse JSON data. Naturally should the input string not be of valid JSON format, the function would error out. That is because handling invalid JSON data is out of the scope …