Skip to content

impossible to inspect http requests #109

@lsimone

Description

@lsimone

I cannot log and inspect the HTTP requests executed by nodejs towards an external API.

I read your guide and the paragraph about --browser-field and xhr-request, but I need to use another HTTP client because it is a restful.js dependency, and all the requests it executes are not logged in console and in the network devtool panel.

I tried the most simplified scenario that is the following:

require('request')('https://api.github.com/users/mattdesl/repos', function (error, response, body) {
    console.log('request done', error, response, body)
});

require('xhr-request')('https://api.github.com/users/mattdesl/repos');


Just the second request is reported in devtool network panel and in console.
The first one is executed but I cannot trace it in devtool.
Is there is a solution?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions