Skip to content

[http-server-js][Bug]: wrong value for optional query parameters #9156

@benjlevesque

Description

@benjlevesque

Describe the bug

When using http-server-js, the runtime values of query parameters is not what is described by the type.

In the case of a number, the default value is NaN where it should be undefined.
In the case of a boolean, the default value is false, where it should be undefined.

Reproduction

Here is a repo with the reproduction of each case https://github.com/benjlevesque/repro-typespec-issues/

Checklist

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions