dogear

enter for all results · esc to close

Yoda condition

eslint.orgsite

When you write if ("red" === color) { instead of if (color === "red") { because it reads as, “if red equals the color”, similar to the way the Star Wars character Yoda speaks.

from
Naming
added
2026-10-10
likes
0

similar

  1. Colorify.js github.com

    Simple, customizable, tiny JavaScript color extractor.

  2. XO github.com

    JavaScript happiness style linter ❤️.

  3. Regex Colorizer github.com
  4. arrow functions github.com

    ESLint rules to ensure proper arrow function definitions.

  5. color2k github.com

    A color parsing and manipulation lib.

  6. d-colorize code.dlang.org

Naming › Other: “When you write if ("red" === color) { instead of if (color === "red") { because it reads as, “if red equals the color”, similar to the way the Star Wars character Yoda speaks.”