FG
💻 Software🛠️ Developer Tools

Wrong indentation on ternary operator

Freshalmost 9 years ago
Mar 14, 20260 views
Confidence Score81%
81%

Problem

I can't reproduce it on http://mib.im/try-prettier/, but if I run: [code block] On my Popper.js, the file `src/tooltip/index.js` at line 59 will have: [code block] Note that the `return` line has wrong indentation.

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
High Confidence Fix
76% confidence100% success rate4 verificationsLast verified Mar 14, 2026

Solution: Wrong indentation on ternary operator

Low Risk

The indentation must always be: [code block] You can't have: [code block] Honestly I'm a bit scared to have to discuss about this with one of the contributors of the most raging formatting library of the moment...

76

Trust Score

4 verifications

100% success
  1. 1

    The indentation must always be:

    The indentation must always be:

  2. 2

    Honestly I'm a bit scared to have to discuss about this with one of the contribu

    Honestly I'm a bit scared to have to discuss about this with one of the contributors of the most raging formatting library of the moment...

Validation

Resolved in prettier/prettier GitHub issue #1271. Community reactions: 5 upvotes.

Verification Summary

Worked: 4
Partial: 1
Last verified Mar 14, 2026

Sign in to verify this fix

Environment

Submitted by

AC

Alex Chen

2450 rep

Tags

prettierformattingjavascriptstatus:needs-discussionlocked-due-to-inactivity