Skip to content

Unexpected token when importing #3

Description

@EleotleCram

Is it intentional that you do not provide a compiled npm module?

Now it seems that standard react setups fail to import this module:

Failed to compile.

./node_modules/react-extension-point/lib/ExtensionPoint/ExtensionPoint.js
SyntaxError: ./node_modules/react-extension-point/lib/ExtensionPoint/ExtensionPoint.js: Unexpected token (34:9)

  32 |     return null
  33 |   }
> 34 |   return <Extension {...props} />
     |          ^
  35 | }
  36 | ExtensionPoint.propTypes = {
  37 |   /**

Tried both a CRA (create-react-app) setup and a parcel setup. Both do not expect a native jsx file (which, btw has a .js extension) as an imported module.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions