Search

Nalezeno "javascript": 270

JavaScript Proxy with Storage


The JavaScript Proxy API provides a wealth of “magic” within JavaScript, allowing you to use any object as sort of an alias that allows a wall of validation, formatting, and error throwing. Did you know that you could also employ the Proxy API as an abstraction to different types...

Detect Cryptocurrency by Wallet Address


I’ve always been a massive advocate of cryptocurrency. I love the technology, the ease of use, and the freedom that cryptocurrencies bring to the world. Despite my love of crypto, I know that adoption will take a long time and that the state of crypto is not friendly to new adopters. One scary part...

Set Video Playback Speed with JavaScript


I love that media has moved from custom plugins (Flash…gross) to basic HTML <video> and <audio> elements. Treating these media sources as just another element allows us to use CSS filters to adjust display, for example. The less we need to do with ffmpeg or plugins, the better. I’ve been...

Meet the Developer Who Added Schnorr Signatures to Bcash


This week news.Bitcoin.com spoke with Jonathan Gonzalez, the blockchain developer who is currently maintaining the Bcash project, a Bitcoin Cash full node written in node.js. Gonzalez explained how he got into Bitcoin Cash development and how he managed to get the Bcash node fully compatible with...

Components, yo.


I see VuePress just went 1.0. Explained simply, it's a static site generator based on Vue. But of course, you work in Vue, which means you work in components. All the modern JavaScript frameworks are component-based. Even when they disagree with each other about specific things (like how Svelte...

Everything You Need to Know About Date in JavaScript


Date is weird in JavaScript. It gets on our nerves so much that we reach for libraries (like Date-fns and Moment) the moment (ha!) we need to work with date and time. But we don't always need to use libraries. Date can actually be quite simple if you know what to watch out for. In this article...

How to Detect Text in Images


Images are a great way to communicate without text but oftentimes images are used/abused to spread text within social media and advertisements. Text in images also presents an accessibility issue. The truth is that it’s important, for any number of reasons, to be able to detect text in image...

Level up your .sort game


Sorting is a super handy JavaScript method that can display the values of an array in a certain order. Whether that’s real estate listings by price, burger joints by distance, or best nearby happy hours by rating, sorting arrays of information is a common need. If you’re already doing this with...

Detect if Element is a Web Component


I’ve advocated for web components since before they became a spec, mostly inspired by the Dojo Toolkit’s dijit framework. Empowering first class JavaScript widgets, as opposed to a mess of DIVs and templates, always made the most sense. Now that web components exist, and awesome...

IP Geolocation API


Detecting geolocation information from your user provides you a massive advantage: improved conversion, better segmenting and analytics, and providing more relevant content. There are numerous paid services which will provide geolocation info but they’re oftentimes too costly or short...

Implementing Private Variables In JavaScript


JavaScript (or ECMAScript) is the programming language that powers the web. Created in May 1995 by Brendan Eich, it’s found its place as a widely-used and versatile technology. Despite its success, it’s been met with its fair share of criticism, especially for idiosyncrasies. Things like objects...

Good News for Developers! ConsenSys is Launching ‘Job Kits’


The already booming crypto world is setting structure in place. Now, those developers who are interested in getting into the blockchain space, they will get guidance through a special ‘Job Kit.’ A few days ago, this ‘Job Kit’ is launched by the ETH development studio ConsenSys. How will this...

Resize Observer


Creating websites that are reactive and responsive used to be considered advanced but responsiveness is a necessity for successful websites and apps. We’ve added media queries, matchMedia, and a host of other APIs to help developers make responsiveness easier and now we get a new one:...

Recursive Array.flat


There was much talk about Array.prototype.flat during its early stages, starting with the name alone. Many developers preferred the name flatten but the spec differed from MooTools’ implementation. MooTools would recursively flatten an array but the new, official flat implementation was only...

Using Array reduce


Every developer who specializes in any programming language will tell you there’s a powerful tool the language provides that they rarely use and wish they knew more about. For me, it’s Array.prototype.reduce. I quite enjoy the other Array methods like map, filter, and find, but reduce...

The Thinking Behind Simplifying Event Handlers


Events are used to respond when a user clicks somewhere, focuses on a link with their keyboard, and changes the text in a form. When I first started learning JavaScript, I wrote complicated event listeners. More recently, I've learned how to reduce both the amount of code I write and the number...

Getting To Know The MutationObserver API


MutationObserver watches the DOM, specifically the places you tell it to, like: document.querySelector('#watch-this'); ...and it can tell you (trigger a callback) when stuff happens — like when a child is added, removed, changed, or a number of other things. I used it just the other day...

Type Conversion with JavaScript Arrays


JavaScript’s loose nature allows developers to employ amazing tricks to do just about anything you’d like. I’ve detailed how you can filter falsy values in arrays using a filter(Boolean) trick, but reader David Hibshman shared another trick for typecasting array values the same...

Nahoru
Tento web používá k poskytování služeb a analýze návštěvnosti soubory cookie. Používáním tohoto webu s tímto souhlasíte. Další informace