-

Test Driven Development (TDD) in a nutshell
Every project has somewhere in the src folder a file called utils.js, Utils.java, utils.py, etc. A couple of days ago I was looking for a way to generate a random float number between two integer numbers. Utils.xx was a good place to put a function called getRandomNumberBetween(min,max). In my case I was working with Node.js, Read more
-
Compress a file in Node.js
Compress a file in Node.js without extra dependencies. const zlib = require(‘zlib’); const fs = require(‘fs’); /** * * @param filePath the absolute path to the will to zip * @return {Promise} the full absolute path to the zip file */ function zip(filePath) { return new Promise((resolve, reject) => { const zipFilePath = `${filePath}.zip`; pipeline( Read more
-
Load stylesheets in background to increase page speed
With only two simple steps your pages will load faster, and the most important: using only native JavaScript The trick will be to use a default tag in rel attribute and modify it once the page loads Step 1 Include your stylesheets this way <link id=”stylesCss” as=”style” rel=”preload” href=’/stylesheets/style.css’ /> Step 2 After the page Read more
-

How to configure http auth basic in Node js and Express
Let’s build a small site in Node.js using Express that will have one protected page We are going to use express generator to generate some scaffolding. If you didn’t install it just type this command to install it globally but if you already know all this stuff you might skip this step npm install express-generator Read more
-

Post 6 – Building Your First Lightning Web Component for Salesforce Series
This will be the sixth of a series of posts I will be doing over the next few weeks. They will all lead up to the introduction of my new course in December 2019 titled, “Building Your First Lightning Web Component for Salesforce” from Pluralsight. These posts will contain final code snippets of the code… Read more
-

sforce.apex.execute in Lightning
You are here because your JavaScript buttons that worked in Classic doesn’t work in Lightning.View post to subscribe to site newsletter. Read more