Skip to content

bug: bundled domino incorrectly returns undefined instead of null for querySelector #51068

Closed
angular/domino
#57

Description

@liamdebeasi

Which @angular/* package(s) are the source of the bug?

platform-server

Is this a regression?

No

Description

The version of Domino bundled with Angular returns undefined instead of null for querySelector.

This is causing deprecation warnings in Ionic to be incorrectly logged since we expect querySelector to return either the Element or null as per the Element.querySelector spec.

Ionic issue: ionic-team/ionic-framework#27564
Relevant Ionic code: https://github.com/ionic-team/ionic-framework/blob/721fc6fd9a21c9c03bb21d290e9b1bbd703e43e3/core/src/components/item/item.tsx#L218


Steps to reproduce

  1. Clone the attached repo.
  2. Run npm install.
  3. Run npm run dev:ssr.
  4. Once the build process is done, access the app in your browser.
  5. Observe that undefined is logged in the terminal window, but null is logged in the browser console.

Expected Behavior

I expect null to be logged in the terminal window.

Actual Behavior

undefined was logged in the terminal window.

Please provide a link to a minimal reproduction of the bug

https://github.com/liamdebeasi/ng-ssr-test

Please provide the exception or error you saw

No response

Please provide the environment you discovered this bug in (run ng version)

Angular CLI: 16.0.6
Node: 18.12.1
Package Manager: npm 8.19.2
OS: darwin arm64

Angular: 16.1.5
... animations, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, platform-server
... router

Package                         Version
---------------------------------------------------------
@angular-devkit/architect       0.1601.4
@angular-devkit/build-angular   16.1.4
@angular-devkit/core            16.1.4
@angular-devkit/schematics      16.0.6
@angular/cli                    16.0.6
@nguniversal/builders           16.1.1
@nguniversal/express-engine     16.1.1
@schematics/angular             16.0.6
rxjs                            7.8.1
typescript                      5.0.4

Anything else?

No response

Activity

  1. added
    area: server
    on Jul 17, 2023
  2. added this to the needsTriage milestone on Jul 17, 2023
  3. added a commit that references this issue on Jul 17, 2023
    05028b1
  4. JeanMeche commented on Jul 17, 2023

    @JeanMeche
    Member

    Hi, FYI the fork used by Angular has its own repo. I've opened a PR to fix this issue : angular/domino#16 !

    Thanks for reporting this issue 👍

  5. added a commit that references this issue on Mar 28, 2024
    e2a1969
  6. added this to the needsTriage milestone on Apr 11, 2024
  7. added 2 commits that reference this issue on Nov 3, 2026
    d4798c7
    dcf6747
  8. added a commit that references this issue on Nov 12, 2026
    967f599
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area: serverstate: has PR

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions