Html Slim Attributes Without Values

The following SLIM code exists:

input international-phone-number="international-phone-number" type="text"

This code generates HTML code:

<input international-phone-number="international-phone-number" type="text></input>

But I need to get <input international-phone-number type="text></input>

How can i do this? Thank you

+4
source share
1 answer

There were several bug reports on GitHub on GitHub and they implemented support for useless attributes (not sure if it is still in the version temple if you need to use this ). You will need to do the following:

input(international-phone-number type="text")

Make sure you also set :formatto :htmlas follows:

slimrb --option format=:html
+4
source

Source: https://habr.com/ru/post/1570722/


All Articles