Skip to content

Incorrect typing for socket.address()? #93

Closed
@ericleb010

Description

@ericleb010

Description

Typing for TcpSocket.address() seems to be different from what the library returns at runtime.

Steps to reproduce

Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Or code:

// Your code

Current behavior

Calling TcpSocket.address() returns an object that resembles: {family: 'IPv4', port: 54014, address: '192.168.200.143'}

Expected behavior

According to the type definitions, TcpSocket.address() should just be a string: '192.168.200.143'

Screenshots
If applicable, add screenshots to help explain your problem.

Relevant information

OS ?
react-native ?
react-native-tcp-socket ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingreleased

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions