15 amazing things you can do with simple JavaScript 🤯

TLDRDiscover the versatile and surprising capabilities of vanilla JavaScript through practical examples. Learn how to find operating system details, prevent page refreshing, redirect users to new pages, validate emails, get the current URL, and detect mobile browsers. Additional features include handling disabled JavaScript,

•7m read time• From dev.to
Post cover image
Table of contents
Finding operating system details.Preventing the page from refreshing using void(0).Redirecting new page.Validation of emails.Getting the current URL.Detecting a mobile browser using regex.Detecting a mobile browser without regex expression.Detecting disabled JavaScript on the page.To get metadata of a module.Getting the timezone offset from the date.Setting the cursor to wait.To get the status of a checkbox.Adding CSS to console messages.Disable right click on the web page.Capture the browser back button.Grouping and nesting the console output.
100 Comments