Closed trusktr closed 5 years ago
Sorry for the late answer. Is the documentation not clear enough?
tab
designates a single tab as indentation+
indicates the indentation to be relative to the indentation of the opening <script>
tagSo: in your first configuration, you are using "tab"
. The first JS line should be indented with a single tab, no space. Ex:
» » <script>
» const $ = require('jquery')
» ...
Using "+tab"
, you'll need to indent your code relatively to the <script>
tag, ex:
» » <script>
» » » const $ = require('jquery')
» » » ...
By using "+2"
, you'll need to indent your code with 2 spaces relatively to the <script>
tag, ex:
········<script>
··········const $ = require('jquery')
··········...
Let me know if it is not clear.
@BenoitZugmeyer Hi, thanks for the reply. Ah, I get it, so I needed the +
.
I'm trying to learn how the indent rule work. I have some code that I think is formatted well, but I get an error. This my config:
And I get this error:
(same error on that last one).
If I change the config to
'html/indent': '+2',
, then I get the same error on all lines:What does this option do exactly?