eslint_d.js: Frequent slowdowns
I’m using eslint_d through a Sublime extension to auto format https://github.com/TheSavior/ESLint-Formatter and I’m seeing frequently that Sublime reports that it’s become unresponsive, only when using said extension.
I’ve tried running eslint_d via the command line and noticed that while it’s often quick, sometimes it runs as though it’s just warming up for the first time, and therefore takes 30s+ (unfortunately in my project 😦 ). This is when I’ve been saving the same file multiple times so it should have already been cached.
Is there anyway I can debug/find out more information as to why I’m hitting these frequent slow-downs on files that should be cached? I’ve seen there’s eslint_d status, but it doesn’t tell me a huge amount, and running before every file save is going to be awkward 😕
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 21 (9 by maintainers)
@mantoni that looks like a similar problem to the one I hit. The problem is the path to the
project/node_modules/eslint_dis fixed for each project, but this is a global setting for the plug-in. I tried to fix it in a slightly more generic way using the same approach we were going to do witheslint_dbut pushed it into the plugin instead.https://github.com/TheSavior/ESLint-Formatter/pull/90
So I’ve discovered you can set the working directory externally when launching
eslint_das used by another plugin. I feel like this might be a cleaner approach, and not require any changes toeslint_dso I’m going to try that approach first.Cool, thanks @mantoni. Better to get your steer before I try building it.