Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error on export #6

Open
hognogi opened this issue Jun 14, 2018 · 4 comments
Open

error on export #6

hognogi opened this issue Jun 14, 2018 · 4 comments

Comments

@hognogi
Copy link

hognogi commented Jun 14, 2018

I think it's caused by the combination of using es6 import but commonjs export.

My browser gives me this error:

https://i.imgur.com/JvfniYH.png

In order to use the plugin, I need to edit this line in my node_modules folder.

module.exports = class SiteWideBanners {

@hognogi
Copy link
Author

hognogi commented Jun 14, 2018

I recommend simply updating the line to export in es6 style:

export default class SiteWideBanners {

@carsonreinke
Copy link
Contributor

@hognogi This was actually wrong, there is a missing part in the README to note to add a WebPack alias to use the es5 version.

@carsonreinke
Copy link
Contributor

@hognogi Actually, this should be updated, so I am leaving this open.

@hectorfhurtado
Copy link
Contributor

@hognogi, @carsonreinke that note is already on the READM here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants