xojs / SublimeLinter-contrib-xo

SublimeLinter plugin for XO
https://github.com/xojs/xo
MIT License
55 stars 7 forks source link

Automatically configure alternative syntax scopes when available #16

Closed sindresorhus closed 4 years ago

sindresorhus commented 5 years ago

Issuehunt badges

Users can add plugins to XO to enable support for alternative syntax:

It would be useful if the XO binary could have a private CLI flag to share this information and then this plugin could somehow dynamically set the selector setting: https://github.com/xojs/SublimeLinter-contrib-xo/blob/29aac0bc298c1ee98ac4bdbcdd2f7688d48e9a60/linter.py#L13 for the supported syntax scopes.

Currently, the user has to do this manually, which is not a great experience.


This issue requires fairly high understanding of JS and good problem-solving skills.

Some hints on how to solve it here: https://github.com/SublimeLinter/SublimeLinter-eslint/issues/253#issuecomment-416910981


IssueHunt Summary #### [kaste kaste](https://issuehunt.io/u/kaste) has been rewarded. ### Backers (Total: $80.00) - [issuehunt issuehunt](https://issuehunt.io/u/issuehunt) ($80.00) ### Submitted pull Requests - [#20 Implement automatic selector if plugins are used](https://issuehunt.io/r/xojs/SublimeLinter-contrib-xo/pull/20) --- ### Tips - Checkout the [Issuehunt explorer](https://issuehunt.io/r/xojs/SublimeLinter-contrib-xo/) to discover more funded issues. - Need some help from other developers? [Add your repositories](https://issuehunt.io/r/new) on IssueHunt to raise funds. --- IssueHunt has been backed by the following sponsors. [Become a sponsor](https://issuehunt.io/membership/members)
IssueHuntBot commented 5 years ago

@issuehunt has funded $80.00 to this issue.


kaste commented 4 years ago

Hi! 👋

XO uses the standard plugins just like eslint? (T.i. not some variants.) If so, it is basically enough to look at the package.json (dev)Dependencies to see if a plugin is installed. (Strictly, doesn't mean it is also configured well, but that's an edge case.) And if so, XO would pick it up automatically. Basically saying just like with eslint, I don't need a CLI flag to define the used plugins, usually they're configured in the config files.

(I consider implementing this, and want to know how much code share between eslint and XO I could have.)

issuehunt-oss[bot] commented 4 years ago

@sindresorhus has rewarded $72.00 to @kaste. See it on IssueHunt