Closed amadeus closed 7 years ago
https://github.com/hynek/vim-python-pep8-indent/blob/master/indent/python.vim#L65
I don't know if something like this will help though. I'll test soon
I can't reproduce the problem. indent is fine for me without the workaround
also, technically the xml indenter would be the problem
Hmm, you don't get:
const Example = () => (
<section>
<div className="content"></div>
|
</section>
);
I actually get this regardless of whether the filetype is javascript.jsx
or not (in other words, this happens when the filetype is even just javascript
). Are there perhaps other settings I could have that would be causing this?
that would be the correct indent level ( everything within ()
are uniformly lined up ( try indenting line 3) ) with plain javascript. that means you probably have something wrong with the jsx plugin, since for me this indents where you would expect ( at the level of the div ) thanks to the mxw/vim-jsx.
This may not be fixable, but I figured I would post here just in case.
It appears when I use this plugin https://github.com/Yggdroot/indentLine, it breaks indentation.
Specificially, if you set the following indent settings (
tabstop=2
,shiftwidth=2
,expandtab
) and use a JSX snippet like so (|
is the cursor):Then press return/enter, the indentation is completely borked. I think it might have something to do with the conceal chars that IndentLine creates, and if this is the case, you may not be able to work around it :(