Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tabs.ts: Loosen type of SvgGraph.svg #193

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Mar 16, 2022

  1. tabs.ts: Loosen type of SvgGraph.svg

    `@types/jquery` version 3.3.35 and 3.3.36 made some changes to the type
    of JQuery.find(), see the PRs:
    
      * DefinitelyTyped/DefinitelyTyped#43857
    
      * DefinitelyTyped/DefinitelyTyped#44051
    
    As a result, the following line in SvgGraph.setSVG would fail to
    typecheck:
    
    ```typescript
          this.svg = this.container.find('svg')
    ```
    
    But if we change the svg property's type from `JQuery<HTMLElement>` to
    `JQuery<Element>`, we don't have to care about the changes: it typechecks
    either way.
    SamB committed Mar 16, 2022
    Configuration menu
    Copy the full SHA
    16d7b2a View commit details
    Browse the repository at this point in the history