Skip to content
Advertisement

Eslint – Maximum call stack size exceeded

Working in a React / Webpack project I started to have problems with the eslint library.

The eslint package is downloaded using npm and it’s used to validate the project using a webpack preLoader.

JavaScript

It used to work fine until recently when I tried to git clone the same project to an other folder. After installing the dependencies “npm install” and starting the project “npm start” the following error appeared.

JavaScript

The strange part of all is that the old project installation still works.

The problem must be somewhere in the node_modules folder because when I copy the modules from the old installation to the new one the project suddenly works. I did a “npm list –depth=0” on both projects and both have the same packages and versions. Why one is working and the other one not?

I guess the problem is in the eslint package because when I remove the preLoader it works again.

I’m really confused about that. Someone had that problem before?

My main.view.jsx looks like that

JavaScript

Thanks!

Advertisement

Answer

I could solve the problem by myself.

Isolating everything I found out that the problem was the babel dependencies.

For some reason the combination of versions I had of babel-core, babel-loader and babel-eslint where not working properly together. I changed the babel versions required for my project in the package.json and now everything works fine.

JavaScript

Here my eslint dependencies

JavaScript

Hope the time I lost with that will help someone else!

User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement