Skip to content

Inconsistency between textfile and stextfile #273

@Gabriella439

Description

@Gabriella439

textfile uses the URL renderer (i.e. justVarInterpolation = False) whereas stextfile disables the URL renderer (i.e. justVarInterpolation = True). This seems odd because based on their names it seems like textfile and stextfile should behave almost the same except that textfile generates lazy Text whereas stextfile generates strict Text.

However, they don't behave the same, because textfile generates a Haskell expression that expects an additional argument (the render function) whereas stextfile doesn't, so if you were to switch between the two you'd suddenly add or remove a function argument, which is unexpected.

Unfortunately, unifying the two to behave in the same way would be a breaking change, but I wanted to check if (A) this inconsistency was intentional and (B) if it was unintentional, would the maintainers be receptive to a breaking change to textfile to set justVarInterpolation = True?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions