Skip to content

TypeError: Class extends value undefined is not a constructor or null #77

@colingell

Description

@colingell

I could be doing something silly, but when I've imported
import ApiClient from 'cybersource-plugin';
into my nuxt3 application in a .vue page or component I get the below error

which seems to be in the cybersource-rest-client.js file where the Agent class extends http.Agent

TypeError: Class extends value undefined is not a constructor or null
    at node_modules/cybersource-rest-client/node_modules/agent-base/dist/index.js (cybersource-rest-client.js?v=6b63f3c9:2676:36)
    at __require2 (chunk-WGAPYIUP.js?v=6b63f3c9:19:50)
    at node_modules/cybersource-rest-client/node_modules/https-proxy-agent/dist/index.js (cybersource-rest-client.js?v=6b63f3c9:2941:24)
    at __require2 (chunk-WGAPYIUP.js?v=6b63f3c9:19:50)
    at cybersource-rest-client.js?v=6b63f3c9:57284:68
    at node_modules/cybersource-rest-client/src/ApiClient.js (cybersource-rest-client.js?v=6b63f3c9:57291:7)
    at __require2 (chunk-WGAPYIUP.js?v=6b63f3c9:19:50)
    at cybersource-rest-client.js?v=6b63f3c9:161311:35
    at node_modules/cybersource-rest-client/src/index.js (cybersource-rest-client.js?v=6b63f3c9:161313:7)
    at __require2 (chunk-WGAPYIUP.js?v=6b63f3c9:19:50)

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