Skip to content

[Feature] Support multiple header values in Request/Response objects/Request interception #7404

@nexcode

Description

@nexcode
browserContext.route('**', async (route, request) => {
    await route.fulfill({
        status: 200,
        headers: {'set-cookie': 'cookie'}, // headers?: {[p: string]: string}
    });
});

It is impossible to set several identical headers in the map, but cookies are set using multiple set-cookies headers.
NodeJS solves this problem like this: { [p: string]: string | string[] }

Could it be worth doing the same here too?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions