New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
issue with indented script tags in html files #22
Comments
In general I'm not happy with the js-inside-html formatting :( If you can see a way to do this, a PR is certainly welcome! I'm also OK with turning off linting for HTML files, which should not be too difficult... |
i like having the linting in html files. I haven't done anything with python in about 12 years... just looking at the Linter class code, could the lint_view method be overridden? If the file syntax is html and the code ends with a line that is nothing but white space, simply truncate that extra white space (which presumably is in front of the closing script tag), and then call super with the updated code? does that make sense? if so, I can probably figure out how to do that |
If the indent issue doesn't look like it's going to be fixed then js-inside-html formatting needs to be disabled. 👍 |
Hello, @Flet Maybe you want to reconsider adding support for js-in-html because some people have to write JavaScript in HTML. For example, when developing mobile app using Cordova and Framework7. I also feel not OK about this issue. So, my workaround for this issue is to use SublimeLinter-eslint. |
Not against it at all! I've moved on from Sublime and I don't have any
interest in enhancing it myself.
I'm happy to accept pull requests and add maintainers though!
…On Sat, Jun 13, 2020, 12:50 AM Liffindra Angga Zaaldian < ***@***.***> wrote:
Hello, @Flet <https://github.com/Flet>
Maybe you want to reconsider adding support for js-in-html because some
people have to write JavaScript in HTML. For example, when developing
mobile app using Cordova and Framework7.
[image: Jepretan Layar 2020-06-13 pukul 12 47 30 PM]
<https://user-images.githubusercontent.com/3760093/84561149-3aa62500-ad74-11ea-8775-b8c6f7673b62.png>
I also feel not OK about this issue. So, my workaround for this issue is
to use SublimeLinter-eslint
<https://github.com/SublimeLinter/SublimeLinter-eslint>.
[image: Jepretan Layar 2020-06-13 pukul 12 46 50 PM]
<https://user-images.githubusercontent.com/3760093/84561140-2eba6300-ad74-11ea-9e13-8f8904b3f654.png>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#22 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACX6KLUFP7RT574XTAZKLDRWMHR5ANCNFSM4CELBC3Q>
.
|
If the script tag is indented, is there a way to get standard to not complain about the space before the closing script tag?
this will give the error for trailing spaces not allowed as well as no newline at and of file, but if I don't indent the closing script tag, it's fine. My OCD hates having script tags nested in other tags not be indented, but it also hates having red marks from Standard linter.
is there a way to suppress that error without having to add an ignore rule to every script tag block?
The text was updated successfully, but these errors were encountered: