Skip to content
This repository has been archived by the owner on Apr 21, 2021. It is now read-only.

Bundle using Webpack . #234

Closed
anoopd opened this issue Dec 7, 2017 · 1 comment
Closed

Bundle using Webpack . #234

anoopd opened this issue Dec 7, 2017 · 1 comment

Comments

@anoopd
Copy link

anoopd commented Dec 7, 2017

I was trying to bundle senna with webpack and when i try to initialize it is showing error

Uncaught TypeError: _senna2.default.App is not a constructor at Object.defineProperty.value (app.js:15) at __webpack_require__ (bootstrap fb4f791f5a0ac65d2f0b:19) at Object.<anonymous> (bundle.js:9515) at __webpack_require__ (bootstrap fb4f791f5a0ac65d2f0b:19) at module.exports.ctor.super_ (bootstrap fb4f791f5a0ac65d2f0b:62) at bootstrap fb4f791f5a0ac65d2f0b:62

Can somebody show what i did wrong ?
My app.js file is

` import Senna from 'senna' ;

var app = new Senna.App();`
@brunobasto
Copy link

brunobasto commented Dec 12, 2017

Hey @anoopd,

If you take a look at our main file, senna.js , we export the App class by default. So, I imagine you meant to import it like this:

import App from 'senna';

var app = new App();

@jbalsas jbalsas closed this as completed Nov 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants