MCPcopy Index your code
hub / github.com/capricorn86/happy-dom

github.com/capricorn86/happy-dom @v20.10.6 sqlite

repository ↗ · DeepWiki ↗ · release v20.10.6 ↗
5,630 symbols 15,432 edges 992 files 2,923 documented · 52% 76 cross-repo links
README

Happy DOM Logo

A JavaScript implementation of a web browser without its graphical user interface.







<a href="https://www.npmjs.com/package/happy-dom">
    <img alt="Published on NPM" src="https://img.shields.io/npm/v/happy-dom.svg">
</a>







<a href="https://github.com/capricorn86/happy-dom/wiki/">Documentation</a> | <a href="https://github.com/capricorn86/happy-dom/wiki/Getting-started">Getting started</a> | <a href="https://github.com/capricorn86/happy-dom/wiki/Setup-as-Test-Environment">Setup as Test Environment</a>

DOM Features

  • Custom Elements (Web Components)

  • Declarative Shadow DOM

  • Mutation Observer

  • Tree Walker

  • Fetch API

And much more..

Works With

Sponsors

Sponsors

<a href="https://sentry.io/"><img alt="Sentry" width="50px" src="https://avatars.githubusercontent.com/u/1396951?s=200&v=4"></a>
&nbsp;&nbsp;
<a href="https://canonical.com/"><img alt="Canonical" width="50px" src="https://avatars.githubusercontent.com/u/53057619?s=200&v=4"></a>

Backers

<a href="https://sourcegraph.com/"><img alt="Sourcegraph" src="https://images.weserv.nl/?url=avatars.githubusercontent.com/u/3979584?v=4&h=40&w=40&fit=cover&mask=circle&maxage=7d"></a>
&nbsp;&nbsp;
<a href="https://github.com/andykenward"><img alt="andykenward" src="https://images.weserv.nl/?url=avatars.githubusercontent.com/u/4893048?v=4&h=40&w=40&fit=cover&mask=circle&maxage=7d"></a>
&nbsp;&nbsp;
<a href="https://github.com/raystubbs"><img alt="raystubbs" src="https://images.weserv.nl/?url=avatars.githubusercontent.com/u/7083791?v=4&h=40&w=40&fit=cover&mask=circle&maxage=7d"></a>

Contributing

See Contributing Guide.

License

MIT License © 2019-Present David Ortner

Extension points exported contracts — how you extend this code

IBrowserFrame (Interface)
(no doc) [6 implementers]
packages/happy-dom/src/browser/types/IBrowserFrame.ts
IWorkerWaitingItem (Interface)
(no doc)
packages/@happy-dom/server-renderer/src/ServerRenderer.ts
IBrowserContext (Interface)
(no doc) [6 implementers]
packages/happy-dom/src/browser/types/IBrowserContext.ts
IServerRendererConfiguration (Interface)
(no doc)
packages/@happy-dom/server-renderer/src/types/IServerRendererConfiguration.ts
IModule (Interface)
(no doc) [8 implementers]
packages/happy-dom/src/module/types/IModule.ts
IServerRendererResult (Interface)
(no doc)
packages/@happy-dom/server-renderer/src/types/IServerRendererResult.ts
IBrowserPage (Interface)
(no doc) [4 implementers]
packages/happy-dom/src/browser/types/IBrowserPage.ts
IOptionalServerRendererConfiguration (Interface)
(no doc)
packages/@happy-dom/server-renderer/src/types/IOptionalServerRendererConfiguration.ts

Core symbols most depended-on inside this repo

createElement
called by 1924
packages/happy-dom/src/nodes/document/Document.ts
setAttribute
called by 1824
packages/happy-dom/src/nodes/element/Element.ts
getAttribute
called by 1340
packages/happy-dom/src/nodes/element/Element.ts
appendChild
called by 1313
packages/happy-dom/src/nodes/node/Node.ts
push
called by 508
packages/happy-dom/src/history/HistoryItemList.ts
get
called by 495
packages/happy-dom/src/fetch/cache/response/IResponseCache.ts
getPropertyValue
called by 453
packages/happy-dom/src/css/declaration/CSSStyleDeclaration.ts
setProperty
called by 428
packages/happy-dom/src/css/declaration/CSSStyleDeclaration.ts

Shape

Method 4,345
Class 1,012
Interface 126
Function 102
Enum 45

Languages

TypeScript100%

Modules by API surface

packages/happy-dom/src/css/declaration/CSSStyleDeclaration.ts800 symbols
packages/happy-dom/src/window/BrowserWindow.ts186 symbols
packages/happy-dom/src/nodes/document/Document.ts183 symbols
packages/happy-dom/src/nodes/svg-element/SVGElement.ts98 symbols
packages/happy-dom/src/nodes/element/Element.ts92 symbols
packages/happy-dom/src/css/declaration/property-manager/CSSStyleDeclarationPropertySetParser.ts92 symbols
packages/happy-dom/src/nodes/html-element/HTMLElement.ts88 symbols
packages/happy-dom/src/window/WindowContextClassExtender.ts87 symbols
packages/happy-dom/src/nodes/html-media-element/HTMLMediaElement.ts67 symbols
packages/happy-dom/src/dom/dom-matrix/DOMMatrixReadOnly.ts67 symbols
packages/happy-dom/src/nodes/html-input-element/HTMLInputElement.ts65 symbols
packages/happy-dom/src/nodes/svg-svg-element/SVGSVGElement.ts51 symbols

Dependencies from manifests, versioned

@angular/common22.0.0 · 1×
@angular/compiler22.0.0 · 1×
@angular/core22.0.0 · 1×
@angular/platform-browser22.0.0 · 1×
@happy-dom/global-registrator0.0.0 · 1×
@jest/environment30.0.0 · 1×
@jest/fake-timers30.0.0 · 1×
@jest/types30.0.0 · 1×
@lit/reactive-element1.3.1 · 1×
@testing-library/react14.0.0 · 1×
@testing-library/user-event14.5.1 · 1×

For agents

$ claude mcp add happy-dom \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact