In this another small article I am going to explain what is different between JIT and AoT in Angular and which one is better.
Just In Time (JIT) and Ahead of Time (AoT) is Angular compiler which runs in Angular background
Just in Time (JIT)
Inefficent for...
Read More ⟶
Hello Guys, In this small article I am going to show you how with JavaScript recursive method to find Fibonacci sequence of numbers with very simple technique.
A small introduction to know what is a Fibonacci series. Its a sequence of number very popular. Every...
Read More ⟶
JavaScript Algorithm to find all possible anagram of a string.
let genAnagrams = (word, n, anagram = '', anagrams = []) => {
word = word.toUpperCase();
if(anagram) {
anagrams.push(anagram)
}
if(!word) {
return
}
...
Read More ⟶
In this small article I am going to show you how we can easily perform a recursive method to add sum of integers till the given number.
let sum = (n)=> n ? n + sum(n-1) :...
Read More ⟶
Sometime we might just need to know the git url where we are updating all our day to day work. It might be the reason you wanted to share the url with your colleague. Below command can be useful in order to get git url
git config --get remote.origin.url
git...
Read More ⟶
Debounce in JavaScript generally states that you want to delay a function in particular event. Events such as mouse move, click etc. Lets take an example:- you have an event of mouse move on a button. When you move your mouse over the button it will fire the event...
Read More ⟶
Multiple bracket function in JavaScript are tricky to understand. The bracket generally resemble a function without bracket it would be a variable. So, if you want multiple bracket function you would need to return multiple function in it. For eg: look at the code...
Read More ⟶
Call, Apply and Bind in JavaScript are very powerful function that allows you to borrow object properties and method. To understand this I am going to put a very simple example to output same result using all three function. (call, apply and bind). Let us look at the...
Read More ⟶
var expression = /[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)?/gi;
var regex = new RegExp(expression);
var t = 'www.facebook.com';
if (t.match(regex)) {
alert("Successful match");
} else {
alert("No...
Read More ⟶
As a JavaScript developer most of us are pretty familiar with filter method of JavaScript. Like the code below.
let num = [1,2,3,4,5,6];
num.filter(x=> x>2 );
console.log(num); // output is [3,4,5,6]
In the above function we have simply inbuilt filter...
Read More ⟶