question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Trouble Integrating with webpack

See original GitHub issue

Cool library! It’s so fast!

I used the eigenvalue decomposition function from ml-matrix as part of a library that I developed in node, and it worked really well there. I’m trying to bring it over to the browser and I’ve been having trouble importing it in a webpack build. It’s totally the case that most webpack bugs tend to be due to the configurer, but I saw you recently were flipping some stuff around on exports and wanted to double checked.

Specifically my bug is that webpack throws somewhat opaquely on in base.js like so

base.js:4 Uncaught TypeError: __webpack_require__.i(...) is not a function
    at Object.<anonymous> (base.js:4)
    at __webpack_require__ (bootstrap 240ca1a7412a4a4ff7b3:659)
    at fn (bootstrap 240ca1a7412a4a4ff7b3:83)
    at Object.<anonymous> (sub.js:28)
    at __webpack_require__ (bootstrap 240ca1a7412a4a4ff7b3:659)
    at fn (bootstrap 240ca1a7412a4a4ff7b3:83)
    at Object.<anonymous> (number.js:3)
    at __webpack_require__ (bootstrap 240ca1a7412a4a4ff7b3:659)
    at fn (bootstrap 240ca1a7412a4a4ff7b3:83)
    at Object.<anonymous> (ascending.js:3)
(anonymous) @ base.js:4
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
fn @ bootstrap 240ca1a7412a4a4ff7b3:83
(anonymous) @ sub.js:28
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
fn @ bootstrap 240ca1a7412a4a4ff7b3:83
(anonymous) @ number.js:3
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
fn @ bootstrap 240ca1a7412a4a4ff7b3:83
(anonymous) @ ascending.js:3
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
fn @ bootstrap 240ca1a7412a4a4ff7b3:83
(anonymous) @ event.js:73
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
fn @ bootstrap 240ca1a7412a4a4ff7b3:83
(anonymous) @ k-shape.js:4
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
fn @ bootstrap 240ca1a7412a4a4ff7b3:83
(anonymous) @ app.js:4
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
fn @ bootstrap 240ca1a7412a4a4ff7b3:83
(anonymous) @ log-apply-result.js:30
__webpack_require__ @ bootstrap 240ca1a7412a4a4ff7b3:659
module.exports @ bootstrap 240ca1a7412a4a4ff7b3:708
(anonymous) @ bootstrap 240ca1a7412a4a4ff7b3:708
client?e36c:38 

Feel free to close if you think the error is on my end

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:1
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

3reactions
targoscommented, Apr 25, 2019

Version 6.0.0 is now released and should fix this issue.

2reactions
JuliusSkrisacommented, Jul 12, 2018

Hi guys, I have exactly same issue on the same line in base.js:4.

export default class BaseView extends AbstractMatrix() {

AbstractMatrix is not a function after webpack processes the code in my case.

EDIT: I was using @angular/cli 1.2.0 to build. when i have updated to 1.7.0 issue was fixed

so most probably older versions of webpack could not process that construction you have used there.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Integrations - webpack
Cross-platform support can become a problem, but there are several ... Integrating a separate tool adds complexity, so be sure to weigh the...
Read more >
Problem integrating with Webpack - Hotwire Discussion
I'm trying to use Stimulus in a non-Rails application and I've installed Stimulus using NPM and integrated it with Webpack as shown in...
Read more >
Integrating TypeScript with Webpack - Medium
In this lesson, we are going to learn how to compile a TypeScript project using Webpack. This setup becomes necessary if you want...
Read more >
Integration with Webpack - Flexmonster
This tutorial will help you integrate the pivot table with webpack. Follow these steps to set up a simple webpack project using Flexmonster...
Read more >
Webpack 5 Issues | Documentation - Web3Auth
While setting up a new web3 project from scratch, you might face multiple issues with webpack 5. This issue is caused due to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found