Skip to content
This repository was archived by the owner on Aug 18, 2020. It is now read-only.
This repository was archived by the owner on Aug 18, 2020. It is now read-only.

default is not a constructor (with Babel): Error in docs #12

@zoe-edwards

Description

@zoe-edwards

Just been trying this out today. From the examples, I was using this:

const chatkit = new Chatkit.default({
  instanceLocator: 'v1:us1:example',
  key: 'your:key'
});

However, this returns an error:

default is not a constructor

I’m using Babel, so my actual error is:

_pusherChatkitServer2.default.default is not a constructor

I changed my code to this (removing the .default):

const chatkit = new Chatkit({
  instanceLocator: 'v1:us1:example',
  key: 'your:key'
})

And it worked without error.

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