Skip to content

Instantly share code, notes, and snippets.

@NickHatBoecker
Created July 21, 2019 19:38
Show Gist options
  • Select an option

  • Save NickHatBoecker/3c8e7641da712241501cef3e54f208df to your computer and use it in GitHub Desktop.

Select an option

Save NickHatBoecker/3c8e7641da712241501cef3e54f208df to your computer and use it in GitHub Desktop.
eslint autocomplete for Sublime Text 3
{
"completions":
[
{ "trigger": "eslint-disable-line\tDisable rule for this line", "contents": "// eslint-disable-line ${1:rule}" },
{ "trigger": "eslint-disable-next-line\tDisable rule for next line", "contents": "// eslint-disable-next-line ${1:rule}" },
]
}
@Nantris
Copy link
Copy Markdown

Nantris commented Jun 3, 2021

What's the intended usage of this file and resulting behavior? We can't get it to work, even if we try manually specifying a "scope".

@Nantris
Copy link
Copy Markdown

Nantris commented Jun 3, 2021

Works in Sublime 4 oddly.

@NickHatBoecker
Copy link
Copy Markdown
Author

Hey @slapbox,

I always forgot the syntax of "eslint-disable-line" and "eslint-disable-next-line" when I started to work with EsLint.
That's why I used this file in order to add these two terms to Sublime's autocomplete. Whenever I typed "eslint", the editor suggested one of these two, while displaying the help "Disable rule for this line" / Disable rule for next line".

I'm still using Sublime 3, so that's the only version I tested it with.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment