jsdom

A JavaScript implementation of various web standards, for use with Node.js (by jsdom)

Jsdom Alternatives

Similar projects and alternatives to jsdom

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a better jsdom alternative or higher similarity.

Suggest an alternative to jsdom

Reviews and mentions

Posts with mentions or reviews of jsdom. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2021-10-24.
  • Testing Solid.js code beyond jest
    dev.to | 2021-10-24
    jsdom, full-featured, but slow, the default option in jest
  • Developing and Testing Web Components
    dev.to | 2021-10-13
    The next consideration I addressed was being able to easily write and run unit tests for vue-uhtml components. Having previously talked about a unit testing approach for Vue.js components, I was keen to apply the principle of “writing tests that assert your component’s public interface”. Before I could even think about writing component tests, I had to pick the most appropriate and well supported tooling. Vue’s documentation on testing and own vue-test-utils package makes this choice a foregone conclusion with Jest as a comprehensive test framework, and using vue-test-util’s wrapper based API to mount components in an isolated jsdom environment. While jsdom has provided a Custom Elements implementation since version 16, other Web Components APIs including Shadow DOM are not supported or reliable enough to be useful.
  • Making a Toggle Switch into a New HTML Element
    dev.to | 2021-09-24
    I'm highlighting the "against a real browser" bit because doing so provides the highest confidence that the element as it behaves in tests will be the same as it behaves in the wild. This is opposed to using something like jsdom, which has classically had poor support for web components.
  • What's the simplest way to do this?
    Assuming there's no API for this, you'd need to do this with a scraper. Something like JSDom would seem to work for you as you should be able to execute whatever scripts necessary (though I've never used it myself.)
  • Test Driven Development with Svelte - Querying Elements
    dev.to | 2021-08-31
    We are using two functions of testing-library. First we are rendering the component. The test runner, Jest is using jsdom. And it is providing us a browser-like environment. And the testing library is rendering the component into that document. And then we run queries coming with screen to get the elements we are looking for in that document. To get a better view about all available query functions, you can check the testing-library documentation from docs
  • Yes.
    Well there's xmldom and jsdom but they're super heavy and seem like a really backwards solution for server side rendering.
  • What's the best JavaScript web scraper ?
    I recently used https://github.com/jsdom/jsdom
  • Creating a Medium API for Next.js from an RSS feed
    dev.to | 2021-07-24
    jsdom: a pure JavaScript implementation of web standard to emulate a subset of a web browser. We're going to use it for DOM manipulation, handy since some of the RSS response is in HTML.
  • An agnostic, reactive & minimalist (3kb) UI library with direct access to native DOM
    dev.to | 2021-07-16
    You can use a library like JS-DOM to implement a browser context on the server.
  • Time to say goodbye - Enzyme.js
    dev.to | 2021-07-16
    It'd be hard for me to imagine what would it be like back then to write tests if it wasn't for Enzyme. Even with Enzyme, it was noticeably harder than it is today, and I still vividly remember installing and configuring in my project Mocha, Chai, Sinon, and JSDOM, to get pretty much the same tooling that today a single library - Jest - provides out of the box, while adding numerous features on top of that.
  • PerChance and selenium
    reddit.com/r/perchance | 2021-07-14
    It uses JSDOM which is much cheaper/faster than running Selenium or Puppeteer.
  • When preparing a unit test of functionA, is it OK to call functionB, functionC when preparing the test?
    Hi all. I'm writing a unit test for a function which accepts a DOM element as a parameter (functionA(element)). In my unit test, I need to create a DOM element before calling the function under test. To do so, I've used the jsdom npm package to create a mock DOM element. That works fine.
  • Can node interpret DOM?
    So it uses jsdom: https://www.npmjs.com/package/jsdom and not native dom (which node doesnt have).
  • D3 Without the DOM?
    reddit.com/r/d3js | 2021-04-21
    I haven't tried this myself, but it looks like you can use jsdom (and node.js): https://www.gregjopa.com/2020/05/render-d3-charts-server-side

Stats

Basic jsdom repo stats
20
16,505
8.1
4 days ago

jsdom/jsdom is an open source project licensed under MIT License which is an OSI approved license.

Scout APM: A developer's best friend. Try free for 14-days
Scout APM uses tracing logic that ties bottlenecks to source code so you know the exact line of code causing performance issues and can get back to building a great product faster.
scoutapm.com
Find remote JavaScript jobs at our new job board 99remotejobs.com. There are 17 new remote jobs listed recently.
Are you hiring? Post a new remote job listing for free.