Xah Web Dev Blog
WEB MONKEY CANCER
highlights
massive updates
replaced all Object.prototype.hasOwnProperty by Object.hasOwn
- JS: Boolean.prototype
- JS: Function.prototype.name
- JS: Function.prototype
- JS: Number.prototype
- JS: Date.prototype
- JS: Map.prototype
- JS: Iterator.prototype
- JS: RegExp.prototype
- JS: Set.prototype
- JS: String.prototype
- JS: Symbol.prototype
- JS: Object.prototype
- JS: constructor (property)
- JS: prototype (property)
- JS: class (keyword)
- JS: static (keyword)
- JS: delete (operator) π
- JS: Global Functions sans Property Key βprototypeβ
- JS: Function Length Property
- JS: this (binding)
- JS: Getter Setter Properties
- JS: Iterable Interface
- JS: the Set Object Tutorial
lots major updates
- JS: String.fromCodePoint (Char ID to Char)
- JS: String.fromCharCode (Char ID to Char) π
- JS: String.prototype.codePointAt (Char to Char ID) π
- JS: String.prototype.charCodeAt (Char to Char ID) π
- JS: String.prototype.charAt (Extract Char at Index) π
- JS: String.prototype.at (Extract Char at Index)
mega updates.
- JS: Regular Expression Tutorial
- JS: Regular Expression Syntax
- JS: Regular Expression Flags
- JS: Create Regex Object
- JS: Regular Expression Functions
- JS: String.prototype.search
- JS: String.prototype.match
- JS: String.prototype.matchAll
- JS: String.prototype.replace
- JS: String.prototype.replaceAll
- JS: RegExp.prototype.test
- JS: RegExp.prototype.exec
JavaScript abomination, or rather, the abomination of references in programing languages
in JavaScript, regex is always new, never equal.
// JavaScript abomination, or rather, the abomination of references // regex object are never equal console.log(RegExp("x") === RegExp("x")); // false console.log(RegExp("x").source === RegExp("x").source); // true
- why is this false
console.log(/π¦/ === /\u{1F98B}/); - https://x.com/i/grok/share/JV732VQMbU0uyRaRtAV3QnhHx
in which programing language regex are never equal, like in JavaScript (/π¦/ === /\u{1F98B}/)
in which programing language regex are never equal, like in JavaScript (/π¦/ == /x/)
- Advanced, programing language design.
- The abomination of programing language references concept.
- Two identical regex pattens are not equal in many programing languages.
- By the way, in this grok ai answer, it cannot be trusted.
- But, it is true, in some programing language, 2 regexs are equal if the patterns are the same. e.g. Wolfram language.