Skip to content

Error when calling listen on Node's http server #1684

@ntharim

Description

@ntharim

flow has support for Node's http module. However calling listen on a Server instance causes an error that shouldn't exist. Given the following code:

import http from 'http';

const server = http.createServer(() => {});
server.listen(3000, () => {});

The error is:

call of method `listen`
Function cannot be called on any member of intersection type

You can see this on tryflow.org:
http://tryflow.org/#6b0a9f9d52c7320c9e9de182fa081c55

Metadata

Metadata

Assignees

No one assigned

    Labels

    Library definitionsIssues or pull requests about core library definitions

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions