Repository navigation
Releases
Releases · AngleSharp/AngleSharp.Js
1.3.0
Released on Tuesday, November 24 2026.
What's Changed
- Fixed a module with a top-level
awaitblocking the page for many seconds - Fixed import map entries of a prefix not being used
- Fixed an
import()of a module that could not be fetched not rejecting with aTypeError - Fixed the DOM of libraries registered by a creator only being missing
- Fixed an object getting the prototype of an unrelated class of another library
- Updated a WebIDL namespace to be a plain object, whose members are no longer members of the window too
- Updated minimum version of AngleSharp to 1.11.0
- Added
WithJs(DomRegistration)to register the DOM of libraries declared for a scripting engine (#152) - Added
SharedWorker, which the scripts of an origin creating it for the same address - Added CSS module scripts (
import sheet from './a.css' with { type: 'css' }), whose default export is a constructed style sheet - Added
import.meta.resolve() - Added interfaces of a namespace (
[DomExposed("WebAssembly")]putsWebAssembly.Modulethere instead of on the window) - Added delegates of the DOM as functions of scripts
- Added
BigIntegeras BigInt,Memory<Byte>as an ArrayBuffer - Added exceptions of the DOM (e.g.
WebAssembly.RuntimeError) being errors of their class - Added the Web Cryptography API (
crypto.subtle, also in workers; not on .NET Framework) - Released 1.3.0 by @FlorianRappl in #162
Full Changelog: v1.2.3...v1.3.0
1.2.3
Released on Sunday, November 22 2026.
What's Changed
- Fixed
undefinedfor an argument of an enumeration (e.g. thehowofcompareBoundaryPoints) throwing an error scripts could not catch - Fixed event handler attributes of forms and selects (e.g.
form.onsubmit) not being set - Fixed a frame not finding the functions and variables of a script of another window, e.g.
parent.notify() - Fixed
adoptedStyleSheetsnot being an array - Added the constants of the interfaces, e.g.
Node.ELEMENT_NODE,Range.START_TO_ENDorNodeFilter.SHOW_ELEMENT - Added the callbacks of form-associated custom elements, e.g.
formResetCallback - Released 1.2.3 by @FlorianRappl in #160
Full Changelog: v1.2.2...v1.2.3
1.2.2
Released on Sunday, November 15 2026.
What's Changed
- Added the
Audioconstructor (new Audio(src)) - Added
window.event, the event a listener or an event handler runs for, undefined otherwise - Released 1.2.2 by @FlorianRappl in #158
Full Changelog: v1.2.1...v1.2.2
1.2.1
Released on Sunday, November 8 2026.
What's Changed
- Fixed a script inserted by script (e.g.
head.appendChild(script)with its text) running after the script inserting it instead of before the insertion returns (MediaWiki ran the modules cached inlocalStoragetwice: "module already implemented") - Fixed
Function.prototype.toString()givingfunction name() { [native code] }for the functions of scripts instead of their source (MediaWiki stores its modules as the source of their functions);JsScriptingOptions.RetainFunctionSourceTextturns keeping the source off - Released 1.2.1 by @FlorianRappl in #157
Full Changelog: v1.2.0...v1.2.1
1.2.0
Released on Friday, November 6 2026.
What's Changed
- Fixed
window.originbeingnullfor a frame without an address of its own instead of the origin of its creator - Fixed text given to
append,prependand the like failing instead of becoming a text node - Fixed a class deriving from a type of the DOM not having its instances on its prototype chain
- Fixed an object with
handleEventnot being accepted as an event listener, or one withacceptNodeas a filter of aTreeWalkerorNodeIterator - Fixed a function not being accepted as a callback whose result is waited for, e.g. of
navigator.locks.request: it runs on the event loop and is followed to its promise - Fixed promise jobs not running after a timer, a listener or any other callback of the host: they waited for something else to run them, so
awaitcould hang - Fixed a
DOMExceptionwith a name having no code (e.g.NotAllowedError) being namedErrorfor script - Fixed a date from the DOM not being a
Datefor script, and bytes not surviving a structured clone - Fixed a function not being accepted as a callback with a result, e.g. as a filter of a
TreeWalker - Fixed a worker that failed to start throwing from
postMessageinstead of firing anerrorevent - Fixed collections from attributes, e.g.
document.linksorelement.children, not being iterable - Fixed
classListnot being iterable and having noforEach,entries,keysandvalues - Fixed a member of an options dictionary without a default becoming
undefinedin text - Fixed members of the DOM being read-only and copied onto every prototype, so polyfills could neither replace them nor reach derived types (e.g. patching
Element.prototype.querySelector): each is now on the prototype of the interface declaring it, as WebIDL says (writable, enumerable and configurable) - Fixed interface objects of the window being read-only and enumerable:
window.Node = ...now also changesNode, as WebIDL says - Fixed bound functions and callable proxies not being accepted as callbacks (e.g.
setTimeout(f.bind(x)),addEventListener('click', f.bind(x)),requestAnimationFrame(f.bind(x)),onclick), failing withCould not find corresponding cast target - Fixed
removeEventListenernot removing listeners, as a function was turned into another listener each time - Fixed errors of event listeners not reaching the
errorlisteners of the window; an error thrown by such a listener goes to the browsing context - Fixed the address of a script getting lost, so errors and stack traces named
<anonymous>: they tell the resolved address of the script, or of the document for one written into it - Fixed scripts written into a document telling lines and columns of their own in errors and stack traces instead of the ones in the document
- Fixed errors of scripts and of callbacks (e.g. timers, animation frames) not reaching the
errorlisteners of the window; what they don't handle bypreventDefaultgoes to the browsing context - Fixed
onerrorof the window getting the event instead of the message, source, line, column and error, and returningtruenot handling the error - Fixed
errorof anErrorEventbeing a .NET exception instead of what script threw - Fixed an
onclickand the like throwing taking down the process and skipping the other listeners, as it was not reported like a listener - Fixed a
TypeErroror the like thrown for script by a member of the DOM becoming a plainError - Fixed modules being read from the local disk; every module is loaded through the configured requesters (#153) @michaelthyregod
- Fixed modules imported by a relative address being requested from the wrong address (e.g.
./a.jsof/dir/page.htmlfrom/dir/page.html/a.js, and the imports of a module of another origin from the own origin); they are resolved against what imports them (#153) @michaelthyregod - Fixed modules being known by the path of their address, so errors didn't tell the whole address, and imports of an imported module were looked for from the wrong place
- Fixed a module written into a document telling lines and columns of its own, and importing from somewhere other than the base address of the document
- Fixed an error of a module being reported twice
- Fixed an event handler (e.g.
onclick) returningfalsenot cancelling the event - Fixed an event handler attribute being added on top of the previous one when it changed, staying when it was removed, and throwing a syntax error at whoever set the attribute instead of reporting it
- Fixed only the first of several methods or constructors of the same name being callable (e.g.
new URLSearchParams('a=1'),register(url, options)); the one fitting the arguments is called - Fixed static members not being reachable (e.g.
DOMRect.fromRect); they are on the constructor and may take the window as first parameter - Fixed members of classes marked with
DomExposedending up on what they are exposed to (e.g. the members of a constructor onwindow); only extension methods do - Fixed arrays and other iterables not converting to sequences (arrays and the interfaces they implement)
- Fixed
ArrayBuffer, typed arrays, andDataViewnot converting toByte[],ArraySegment<Byte>, andObject(e.g. a request body being sent as[object Uint8Array]) - Fixed numbers not converting from and to
Int64,UInt64,Int16,Byte,SByte,Single(only from), andDecimal, as well as nullable forms of all value types - Fixed values of
DomLiteralsenums being numbers instead of strings (e.g.shadowRoot.mode), and such enums being exposed as objects - Fixed
Byte[]being given as an array of numbers instead of anArrayBuffer - Fixed errors thrown by constructors losing their message
- Fixed WebIDL stringifiers (
URL,URLSearchParams,Location,Range,DOMTokenList,DOMMatrix) answeringString(x)with[object X]; a type overridingToStringhas atoString - Fixed sandboxed browsing contexts without
allow-scriptsrunning scripts and event handler attributes - Fixed
postMessageignoringtargetOrigin, giving it as the origin of the event, turning objects into strings, and not having asource; messages are copied by the structured clone algorithm, and the options form is supported - Added
clearResourceTimingsandsetResourceTimingBufferSizetoperformance - Added
{ type: 'module' }andonerrortoWorker, with imports being loaded by the worker - Added
MessageChannelwith queued message delivery, structured cloning, and transferable ports for windows and workers - Added
IScriptValueCloner, so that values of script can be kept, e.g. by IndexedDB - Added
structuredClone,origin,isSecureContextandlengthto the window - Added
DOMException, which is what the DOM now throws for scripts: anErrorwith thenameandcodeof the standard, also available as a constructor and with its constants - Added
TextEncoderandTextDecoder - Added the iterator of a type giving
entries(WebIDLiterable<K, V>), so that e.g.for (const [k, v] of new URLSearchParams(s))works - Added overloads brought by extensions for the methods of the DOM, as
addEventListenerwith options has them - Added
cryptowithgetRandomValuesandrandomUUID, but withoutsubtle - Added
requestIdleCallbackandcancelIdleCallback - Fixed
DOMParserreplacing the document of the page with what it parsed, and running its scripts - Added
PerformanceObserver, for the marks and measures ofperformance - Added custom elements, run for the registry of AngleSharp: classes deriving from
HTMLElementor another element, with their callbacks running when the call of a script returns (requires AngleSharp 1.10) - Fixed classes deriving from a DOM type taking every object of that type for an instance of them
- Added what a promise rejects with being a
DOMExceptionor what was thrown, if the task behind it failed with one - Added
import.meta.urlto modules; without it, e.g., webpack stopped withAutomatic publicPath is not supported in this browser - Added
ArraySegment<Byte>being given as aUint8Array - Added classes with implicit conversions standing for a WebIDL union, e.g. of a string and a sequence of strings, which fixes such conversions failing; an implicit conversion from such a class is what a script receives for it
- Added the same-origin policy: script gets
nullfor a node of another origin, and for its window aCrossOriginWindowwith onlywindow,self,frames,parent,top,closed,length,location(only to be set, and only for frames inside the own document),postMessage,focus,blurandclose - Added
performance.mark,measure,getEntries,getEntriesByName,getEntriesByType,clearMarks,clearMeasures, along withPerformanceEntry,PerformanceMarkandPerformanceMeasure - Released 1.2.0 by @FlorianRappl in #154
New Contributors
- @FlorianRappl with @Copilot made their first contribution in #149
- @michaelthyregod made their first contribution in #153
Full Changelog: v1.1.4...v1.2.0
1.1.4
Released on Sunday, November 1 2026.
What's Changed
- Fixed callbacks getting their first parameter as
thisinstead of as an argument (e.g. aMutationObservercallback got the observer instead of the records); only a leading window (timers, animation frames) is the receiver - Fixed arrays (e.g. the records of a
MutationObserver) not being JS arrays, sofor...offailed with "The value is not iterable" - Fixed members returning a task (e.g.
fetch) giving an object withoutthen; they return a promise settled on the event loop - Fixed dictionaries (e.g. the parsed body of a JSON response) not being plain JS objects
- Added
unhandledrejection(PromiseRejectionEvent,window.onunhandledrejection); a rejection nobody handles is reported as an error of the browsing context - Released 1.1.4 by @FlorianRappl in #148
Full Changelog: v1.1.3...v1.1.4
1.1.3
Released on Friday, October 30 2026.
What's Changed
- Fixed prepared regular-expression literals ignoring the timeout configured during engine creation @PrzemyslawKlys in #146
- Fixed the console only having
log; it now has all methods of the console standard (e.g.error,warn,info,debug,assert,count,time), as scripts calling or wrapping one of them failed - Fixed reading the globals of scripts (e.g.
var x,x = 1) and the built-ins (e.g.Promise,JSON) throughwindow, which gaveundefined - Fixed named indexers (e.g.
itemofNodeListandHTMLCollection,namedItem) being exposed as properties instead of methods - Fixed functions passed for delegates with value-type or no parameters failing to convert
- Fixed errors thrown by DOM members losing their message
- Fixed only the last of several extension methods of the same name (e.g.
scrollTo(x, y)andscrollTo(options)) being callable; the one fitting the arguments is called - Fixed the geometry stubs of this library (e.g.
offsetHeightalways 0) hiding the implementation of another library (e.g. AngleSharp.Renderer) - Fixed plain objects not converting to dictionaries (classes with
DomNamemembers, e.g.{ top: 100 }toScrollToOptions) - Fixed
datasetrejecting camel-cased names (e.g.dataset.sideNavVisiblefordata-side-nav-visible) with a syntax error - Added
requestAnimationFrame,cancelAnimationFrame,queueMicrotask, andperformance(now(),timeOrigin) to the window - Released 1.1.3 by @FlorianRappl in #147
Full Changelog: v1.1.2...v1.1.3
1.1.2
Released on Sunday, October 25 2026.
What's Changed
- Fixed globals named like a member of the window (e.g.
var item,var open,function close() {}) keeping that member, as the members were copied to the global scope as read-only - Released 1.1.2 by @FlorianRappl in #145
Full Changelog: v1.1.1...v1.1.2
1.1.1
Released on Wednesday, October 7 2026.
What's Changed
- Fixed background thread leaks when worker construction is rejected (#143) @PrzemyslawKlys
- Fixed canonical DOM node identity and concrete prototypes through
DomSameObjectgetters (#141) @PrzemyslawKlys - Added
JsScriptingOptions.EngineCreatorto create a configured Jint engine before any page script runs (#142) @PrzemyslawKlys - Released 1.1.1 by @FlorianRappl in #144
New Contributors
- @PrzemyslawKlys made their first contribution in #141
Full Changelog: v1.1.0...v1.1.1
1.1.0
Released on Saturday, September 5 2026.
What's Changed
- Updated to require at least AngleSharp 1.8.0
- Added support for the
DomReturnTypeattribute - Added support for the
DomSameObjectattribute - Added iterable integration for
IEnumerable<T>instances - Released 1.1.0 by @FlorianRappl in #139
Full Changelog: v1.0.1...v1.1.0