Class constructor Transition/Renderer cannot be invoked without 'new'
See original GitHub issueHi guys,
I was trying to follow the dummy tutorial with Hightway to implement a simple transition between two pages, but I met the same issue as https://github.com/Dogstudio/highway/issues/6. I’m using Webpack 4 with the UglifyJs plugin.
For the record, I added a resolve
with 'build/es5/highway.min.js'
in my webpack, and even copied your babel configuration, but it don’t seem to fix the issue (not a pro user of Webpack though).
Do you know why I meet this error? Anyway, Hightway looks great an I can’t wait to implement it everywhere 🔥!
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Class constructor cannot be invoked without 'new' for TSdx ...
I created a npm package using TSdx for a small Jest reporter. If I use that package in another project, I get the...
Read more >Class constructor Renderer cannot be invoked without 'new' #6
Hi, I followed your basic installation guide but I'm getting the following browser error: Uncaught TypeError: Class constructor Renderer ...
Read more >Javascript ES6 TypeError Class constructor Client cannot be ...
When I try to execute nodemon command I always see this error TypeError: Class constructor Client cannot be invoked without 'new'.
Read more >TypeError: Class constructor HTMLElement cannot be invoked ...
TypeError : Class constructor HTMLElement cannot be invoked without 'new'. This error message has been a headache for me this week.
Read more >Class constructor ServeCommand cannot be invoked without ...
Answers related to “TypeError: Class constructor ServeCommand cannot be invoked without 'new'”. : Timeout - Async callback was not invoked within the 5000 ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
My bad, I managed to understand what you meant in https://github.com/Dogstudio/highway/issues/6 and fixed it (I thought the es5 build was auto-implement with the alias)!
For those who, like me, has trouble to understand, it can be fix by adding the follow line in your webpack, after the
exclude: /node_modules/
:include: '/node_modules/@dogstudio/highway/build/es5/highway.js',
Anway, thanks a lot guys!
@ivandaum I found a better solution to your problem. In your case you exclude completely
node_modules
and if you add a new library you will have to add the new library ininclude.
I prefer to import the right file into javascript:
import Highway from '@dogstudio/highway/build/es5/highway.js';
In the documentation:
import Highway from '@dogstudio/highway';
😊👋