javascript if一行 在 JavaScript 利用表達式優化你的程式碼 - 卡斯伯Blog - 前端 的評價 fn1() : fn2());. 透過此方式可以將多行的 if () { ... } 判斷式縮減成一行,除了行數 ... ... <看更多>
javascript if一行 在 Javascript one line If...else...else if statement - Stack Overflow 的評價 Sure, you can do nested ternary operators but they are hard to read. var variable = (condition) ? (true block) : ((condition2) ? ... <看更多>