News for hackers. Stuff that matters.
Re:Lit: A ridiculously small responsive CSS framework by smlckz on Saturday May 02, 2020 @10:54PM (#23056547)

        .\31{width:5%}
        .\33{width:22%}
        .\34{width:30%}
        .\35{width:40%}
        .\32{width:15%}
huh? can you tell me what those \31 \33 etc. mean?
Re:Lit: A ridiculously small responsive CSS framework by uryga on Saturday May 02, 2020 @11:17PM (#23056620)
TIL! as with most languages, css indentifiers can't start with numbers, but you can get around that using backslash-escapes. you'd use these classes like this:

  <div class="35">

this stackoverflow answer has more info (looks like you can use any symbol you want, even spaces and [{}<>&*] !): https://stackoverflow.com/a/27882887/5534735
Re:Lit: A ridiculously small responsive CSS framework by uryga on Monday May 04, 2020 @09:47PM (#23075513)
just realized my usage example is misleading. as sibling comments correctly explain, \35 means

  chr(0x35) == '\x35' == '5'
so the actual usage would be

  <div class="5">
Re:Lit: A ridiculously small responsive CSS framework by juliend2 on Saturday May 02, 2020 @11:04PM (#23056584)
It means:

    .1{width:5%}
    .3{width:22%}
    .4{width:30%}
    .5{width:40%}
    .2{width:15%}
It's an escape sequence that lets you have non-alphabetic characters to start a CSS selector. See this for more examples:

https://stackoverflow.com/a/35122909/242404

Re:Lit: A ridiculously small responsive CSS framework by duskwuff on Saturday May 02, 2020 @11:09PM (#23056600)
Escapes for "1", "3", "4", "5", and "2".

Probably a workaround for a CSS grammar issue that makes ".1{…}" not parse correctly?