Microsoft/TypeScript

URLSearchParams needs size

Open

#54.466 aberto em 31 de mai. de 2023

Ver no GitHub
 (3 comments) (8 reactions) (0 assignees)TypeScript (6.726 forks)batch import
BugDomain: lib.d.tsHelp Wanted

Métricas do repositório

Stars
 (48.455 stars)
Métricas de merge de PR
 (Mesclagem média 6d 17h) (9 fundiu PRs em 30d)

Description

Bug Report

🔎 Search Terms

URLSearchParams

🕗 Version & Regression Information

TypeScript Version: typescript@4.9.5

  • This is a crash
  • This is the behavior in every version I tried, and I reviewed the FAQ for entries about URLSearchParams.size

⏯ Playground Link

Playground link with relevant code

💻 Code

console.log(new URLSearchParams().size)

🙁 Actual behavior

Property 'size' does not exist on type 'URLSearchParams'.ts(2339)

🙂 Expected behavior

No error

Related bug:

https://github.com/microsoft/TypeScript/issues/38139

Note: Adding { "lib": ["dom.iterable"] } to my compilerOptions does not help.

Guia do colaborador