Skip to content

Missing computed properties on expando functions Β #54811

Closed
@dragomirtitian

Description

@dragomirtitian

Bug Report

πŸ”Ž Search Terms

expando functions computed properties

πŸ•— Version & Regression Information

  • This is the behavior in every version I tried, and I reviewed the FAQ

⏯ Playground Link

Playground link with relevant code

πŸ’» Code

const c = "C"
export function decl () {}
// decl.foo = ""
decl["B"] = 0
decl[c] = 0

πŸ™ Actual behavior

Properties "B" and "C" are not present in the generated declarations unless decl.foo is uncommented.

πŸ™‚ Expected behavior

Properties "B" and "C" should be present in the generated declaration regardless of the presence of foo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptHelp WantedYou can do this

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions