Skip to content

False positive on the UnnecessaryStringOutput cop #500

@ydakuka

Description

@ydakuka

Describe

I have the haml code:

= "#{user.payment_price_btc}\u202F\u0243"

On the browser page:

0.01000000 Ƀ

I run haml-lint and I get:

ydakuka@yauhenid:~/Work/project$ haml-lint ./app/views/users/
app/views/users/_list.html.haml:59 [W] UnnecessaryStringOutput: `= "..."` should be rewritten as `...`

45 files inspected, 1 lint detected

However, if I follow the recommendation, I'll get the following haml code:

#{user.payment_price_btc}\u202F\u0243

And this, on the browser page:

0.01000000\u202F\u0243

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions