Latest Tutorials and How-To's
Without cookies being enabled in the browser, some web applications may not work as expected. To prevent such cases navigator.cookieEnabled property can be used to do a prior check whether cookies are enabled or not.
January 5, 2020
Browsers allow user-sensitive and low-level web APIs to execute only when the page is in a secure context. In addition, the window.isSecureContext property can be used to check whether the current environment is safe or not.
January 2, 2020
The new CSS properties such as text-decoration-thickness, text-decoration-color etc can help in creating attractive text decorations and underlines, which were not possible before.
January 1, 2020
The referring url may compromise user privacy when a link is clicked. However this can be prevented through the referrer meta tag, or using the referrerpolicy attribute on hyperlinks.
December 29, 2019
Giving user the preference of choosing a dark or light mode has become a very popular feature of operating systems. Webpages can also be shown in dark or light theme depending on the mode chosen in the device settings.
December 28, 2019
The ping attribute can be included in link tags to notify the server when the link is clicked. This can be used for tracking purposes.
December 26, 2019
December 25, 2019
HTML videos can be lazily loaded using the preload attribute of the 〈video〉element. preload="none" needs to be set to disable pre-loading of the video.
December 24, 2019
Variable fonts is a new font technology that allows a single font file to store multiple variations of the font. Variable fonts are going to bring a major change in web design.
December 22, 2019
The Array.fill() method can be used to fill an array with a specific value, starting from a given index and ending upto another index.
December 21, 2019
December 19, 2019
December 18, 2019
The finally() callback can be used to know whether the Promise was settled. We don't care whether it was resolved or rejected.
December 17, 2019
December 16, 2019
Time delay for setTimeout() / setInterval() methods executing on inactive browser tabs are set to one second regardless of their value defined in code.
December 15, 2019
When a fixed-position modal dialog is opened, scrollbars on the page can be removed by dynamically setting overflow:hidden CSS for the 〈body〉tag.
December 14, 2019
Pull-to-refresh feature on mobile browsers that refreshes the page, can be disabled using the overflow-behaviour CSS property.
December 13, 2019
The "decoding" attribute can be included for an 〈img〉tag to specify whether to decode the image in parallel or along with the rest of the page content.
December 12, 2019
The Object.seal() method seals an object. After an object gets sealed, no new properties can be added to it.
December 11, 2019
The Object.freeze() method can make an object or array immutable. No changes can be made to that object once it gets immutable.
December 10, 2019
Intersection Observer Now Also Accepts a Document as the Root Element
Better Caching With stale-while-revalidate Directive in Cache-Control Header
Synchronous AJAX Will Not Work in Page Dismissal Events