Explain Codes LogoExplain Codes Logo

Javascript

History.replacestate() example?

javascript
history-api
browser-terrain
cross-browser-inconsistencies

Sound effects in JavaScript / HTML5

javascript
web-audio-api
audio-engineering
browser-compatibility

How to get the HTML for a DOM element in JavaScript

javascript
prompt-engineering
functions
callbacks

Detecting real time window size changes in Angular 4

javascript
responsive-design
performance
best-practices

Getting the parent div of an element

javascript
dom-traversal
javascript-methods
performance-optimization

How do I format a date as ISO 8601 in moment.js?

javascript
moment-js
date-formatting
iso-8601

Vue.js data-bind style backgroundImage not working

javascript
vuejs
javascript-best-practices
template-literals

How do I retrieve an HTML element's actual width and height?

javascript
getboundingclientrect
offsetwidth
offsetheight

Why does Prettier not format code in VS Code?

javascript
prompt-engineering
vscode-settings
prettier-configuration

Converting an object to a string

javascript
object-serialization
json-stringify
browser-compatibility

Generic way to detect if HTML form is edited

javascript
form-engineering
event-listeners
mutation-observers

Can I execute a function after setState is finished updating?

javascript
react-hooks
state-management
functional-components

Can I escape HTML special chars in JavaScript?

javascript
html-escaping
security-best-practices
javascript-libraries

How do you round to one decimal place in JavaScript?

javascript
rounding
math-functions
precision

Changing website favicon dynamically

javascript
dom-manipulation
jquery
favicon

How to change the href attribute for a hyperlink using jQuery

javascript
jquery
javascript-advanced
performance

How can I change div content with JavaScript?

javascript
event-delegation
dom-manipulation
accessibility

Trying to use fetch and pass in mode: no-cors

javascript
cors-proxy
fetch-api
cross-origin-resource-sharing

Dynamic tag name in React JSX

javascript
dynamic-rendering
jsx
react-components

Angular2 disable button

javascript
angular
button-state
form-validation