• Kyle Keating's avatar
    Prevent 0 flag count from rendering in DOM · 496af7f8
    Kyle Keating authored
    Preact exhibits funny behavior for inline conditionals that don’t resolve to an actual boolean value. When the flagCount variable is 0 it renders the conditional statement directly in the dom. Casting to a boolean prevents this.
    496af7f8
moderation-banner.js 2.7 KB