Skip to content

[css-flexbox-1] Change flex shorthand of flex:1 back to setting a flex-basis of 0%. #10782

@bfgeek

Description

@bfgeek

https://drafts.csswg.org/css-flexbox-1/#change-2015-flex-basis-zero

<!DOCTYPE html>
<body style="flex:1">
<script>
document.body.innerText = getComputedStyle(document.body).flexBasis;
</script>

Basically nobody implemented this change when it was made in the spec. ~10 years later all browsers currently set the flex-basis to 0%, instead of 0px.

This change won't be web-compatible now, and should be reverted back to setting 0% as the flex-basis.
(before my time - reading about this - part of the rationale was to help fix the intrinsic-sizing algorithm, but that also isn't web-compatible).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions