Hello Everyone, If anyone wants to be a Programming related content creator on the Educative.io website please share your email and a short description about the topic you're good with to the email firstname.lastname@example.org. I will forward your email to the Educative.io Content Creator selection group. They will have a small discussion with you and decide further. After you have been selected as a content creator, you will be get paid(They Pay well for your work) for the content you create.
The Screen Wake Lock API can prevent a user’s computer screen from turning off so that they can work undisturbed.
Check if your browser supports the Screen Wake Lock API…
findIndex()method returns the index of the first element of the array if the callback function passed to the
findIndexmethod returns true, otherwise returns -1
arr.findIndex(callback( element, index, array ) ,thisArg)
callback function→ A function to execute on each value in the array until the function returns
true, indicating that the satisfying element was found.
thisArg→ Optional object to use as
callback function takes three arguments
element→ current processing element
index (Optional)→ index of the element…
Learn how to improve the performance of rendering in canvas by using OffscreenCanvas
The OffscreenCanvas interface allows canvas rendering contexts (2D and WebGL) to be used in Workers. It increases parallelism in the web, leading to improved performance on multi-core systems.
Using OffscreenCanvas we can render a canvas in the worker thread so that the main thread will be undisturbed so that our web app will work smoothly.
The support of OffscreenCanvas across the browser can be found here CanIUse.
There are two ways we can use
Object.preventExtensions() method prevents new properties from added to an object.
In the above code, after calling
preventExtensions on the
user object, when we try to add
preventExtensionsmethod returns the object being made non-extensible.
extensibleagain once it has been made
non-extensiblewe can use
preventExtensions()method only prevents addition of own properties. …
split method spilt the string into array of substring based on the pattern provided.
let numbersStr = "1,2,3,4,5";let numArray = numbersStr.split(",");console.log(numArray); // ["1","2","3","4","5"]
In the above example , the split method will loop through all the character of the string , if the pattern provided is found then the split method will collect the characters looped before finding the pattern and join all the characters as a string and pushed that string into an array .
If we don’t pass any pattern then the entire string will be pushed to an…
XHRwe can update the page based on the user action.
XHR, we can make both synchronous and asynchronous requests.
let request = new XMLHttpRequest();
To configure the…
You can use
method to check if a primitive value present in an array, Consider we have an array
var num = [1,2,3,4,5];
indexOf() method returns the first index of the element in the array, if the searching element is not present in the array then it returns
num.indexOf(3); // 2num.indexOf(6); //-1num.indexOf('3'); // -1
NaN value is not handled in
var array = [NaN];array.indexOf(NaN); // -1
If your array can…
Requesting donation for my Badminton Training.
Hello Reader, My name is Jagathish Saravanan, I am from India. I am currently working as a Web developer , I love my Job , but once I started playing Badminton , I started loving Badminton more that anything , So I have decided to switch my carrer to Badminton, It is hard to manage my training expense , so I started writing Blog in Medium . But medium partner program is not supported in India. So I am requesting you to donate some amount .
You can donate me in PayPal :
Google pay: 8015851838.
Thank you so much for your time