havenwood changed the topic of #ruby to: Ruby 3.4.4, 3.3.8, 3.5.0-preview1 https://www.ruby-lang.org | Log https://libera.irclog.whitequark.org/ruby
<The_Camel> havenwood, what's your favourite CSS framework?
<The_Camel> think I mentioned it before but, ultimately, after some reflection, a huge portion of web development ultimately results in a lot of front end CSS code.
<The_Camel> like, as much as 70% lol
<The_Camel> mixed in with html
<The_Camel> I want to get into tailwind but
<The_Camel> the mandatory vue.js kinda makes me wanna scratch my back.
<weaksauce> wat
<weaksauce> why would you need vue
<The_Camel> weaksauce, look at the components and docs. they're using vue code heavily.
<weaksauce> The_Camel i don't need to it's framework agnostic
<The_Camel> weaksauce, I would've thought that too until I looked at it.
<The_Camel> it's like aliexpress' css/ui framework. that too requires vue.js
<weaksauce> post your homework here. i don't buy it one second
<The_Camel> weaksauce, sure. here's a navbar - https://catalyst.tailwindui.com/docs/navbar
<The_Camel> their components are also (apparently) behind a tailwind(plus) wall.
<The_Camel> called tailwind-ui (?)
<The_Camel> here's a sidebar - https://catalyst.tailwindui.com/docs/sidebar
<The_Camel> vue code.
<The_Camel> or react. either or. they both look very similar.
<weaksauce> yeah you have to pay for those and they give you three options
<weaksauce> html, react, vue
<The_Camel> weaksauce, I might've missed the "options". where is that?
<weaksauce> i don't know where catalyst.tailwindui.com is from but that's not really tailwind proper
<weaksauce> you don't need to use their "components"
<The_Camel> I don't? So how does one get a navbar in tailwind, in plain html/css ?
<weaksauce> you make it yourself
<weaksauce> with tailwind
<The_Camel> BLEH!
<weaksauce> or you pay them
<The_Camel> naw. naw. bootstrap gives you a navbar without making it myself.
<The_Camel> xD
<The_Camel> weaksauce, that is nasteh.
<weaksauce> i don't like tailwind even but what you were saying is hogwash
<The_Camel> weaksauce, which part exactly? maybe I may have confused tailwind with tailwind-ui, sure. but
<The_Camel> ok. the "vue/react/html" part, probably.
cappy has left #ruby [Leaving]
<The_Camel> weaksauce, at this rate, I'd rather install vue and switch to aliexpress/alibaba's framework if I have to build a navbar by myself :D
<The_Camel> or just pull in bootstrap
<The_Camel> X!
<The_Camel> I swear to Imhotep, if one day I win the lottery, I'm also gonna make a 3rd company with an army of developers to make a CSS framework.
The_Camel_ has joined #ruby
* The_Camel_ makes camel noises.
The_Camel has quit [Ping timeout: 272 seconds]
nirvdrum7418 has joined #ruby
nirvdrum741 has quit [Read error: Connection reset by peer]
nirvdrum7418 is now known as nirvdrum741
fercell has quit [Quit: ZNC - https://znc.in]
fercell has joined #ruby
Linux_Kerio has quit [Ping timeout: 244 seconds]
brw has quit [Remote host closed the connection]
brw has joined #ruby
Vonter has joined #ruby
ih8u has quit [Quit: ih8u]
mountroot has joined #ruby
mountroot has quit [Client Quit]
ih8u has joined #ruby
grenierm has joined #ruby
ap4y has quit [Remote host closed the connection]
wbooze has joined #ruby
mange has joined #ruby
cybniv has quit [Read error: Connection reset by peer]
niv has joined #ruby
schne1der has joined #ruby
jmcantrell has quit [Ping timeout: 268 seconds]
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
infinityfye has joined #ruby
wanderfish has quit [Quit: quits]
acosta7 has joined #ruby
acosta has quit [Quit: Ping timeout (120 seconds)]
acosta7 is now known as acosta
grenierm has quit [Ping timeout: 272 seconds]
dionysus69 has joined #ruby
rvalue has quit [Ping timeout: 245 seconds]
TomyWork has joined #ruby
ua_ has quit [Ping timeout: 276 seconds]
ua_ has joined #ruby
rvalue has joined #ruby
acosta has quit [Read error: Connection reset by peer]
acosta has joined #ruby
otisolsen70 has joined #ruby
Linux_Kerio has joined #ruby
nyoki has joined #ruby
acosta4 has joined #ruby
acosta has quit [Read error: Connection reset by peer]
acosta4 is now known as acosta
schne1der has quit [Ping timeout: 272 seconds]
weaksauce has quit [Ping timeout: 244 seconds]
TomyWork has quit [Quit: Leaving]
weaksauce has joined #ruby
TomyWork has joined #ruby
o0x1eef has quit [Ping timeout: 252 seconds]
schne1der has joined #ruby
fantazo has joined #ruby
GreenResponse has joined #ruby
rvalue has quit [Ping timeout: 276 seconds]
rvalue has joined #ruby
johnjaye has quit [Ping timeout: 260 seconds]
o0x1eef has joined #ruby
otisolsen70 has quit [Read error: Connection reset by peer]
mange has quit [Quit: Zzz...]
tronexte has quit [Ping timeout: 248 seconds]
tronexte has joined #ruby
polishdub has quit [Remote host closed the connection]
johnjaye has joined #ruby
<The_Camel_> weaksauce, o0x1eef do you happen to know something like this, but for ruby? I need a good "one size fits all" guide for ruby, covering rails, rack, general macroframeworks, and whatnot. https://www.fullstackpython.com/
<The_Camel_> because whoever made fullstack python, did indeed do what I wanted.
nyoki has quit [Quit: WeeChat 4.6.3]
<o0x1eef> Hm no, nothing quite like that but there's https://www.ruby-toolbox.com/
<The_Camel_> o0x1eef, I like it. I'll take it. cheers.
polishdub has joined #ruby
user71 has joined #ruby
schne1der has quit [Quit: schne1der]
schne1der has joined #ruby
weaksauce has quit [Ping timeout: 260 seconds]
dionysus69 has quit [Ping timeout: 252 seconds]
ih8u2 has joined #ruby
ih8u has quit [Ping timeout: 260 seconds]
ih8u2 is now known as ih8u
jmcantrell has joined #ruby
oznek has joined #ruby
wbooze has quit [Quit: Leaving]
inline has joined #ruby
svm has joined #ruby
msv has quit [Ping timeout: 248 seconds]
nyoki has joined #ruby
schne1der has quit [Ping timeout: 248 seconds]
nyoki has quit [Quit: WeeChat 4.6.3]
o0x1eef has quit [Quit: brb]
o0x1eef has joined #ruby
o0x1eef has quit [Client Quit]
o0x1eef has joined #ruby
Vonter has quit [Read error: Connection reset by peer]
schne1der has joined #ruby
nekobit has joined #ruby
weaksauce has joined #ruby
nmollerup has quit [Quit: Leaving]
TomyWork has quit [Ping timeout: 252 seconds]
<havenwood> The_Camel_: Just swap Django for Rails and Falcon for Roda and it's mostly the same.
<havenwood> Sorry, I meant Flask for Roda.
<havenwood> Falcon is Falcon.
<The_Camel_> havenwood, I will keep that in mind.
<The_Camel_> the chorus at 2:00 is so addictive.
infinityfye has quit [Read error: Connection reset by peer]
<The_Camel_> one day
<The_Camel_> I will make this larger
<The_Camel_> and end in China.
<The_Camel_> I can't wait.
cata has joined #ruby
cata has quit [Changing host]
cata has joined #ruby
Linux_Kerio has quit [Ping timeout: 276 seconds]
schne1der has quit [Ping timeout: 248 seconds]
user71 has quit [Quit: Leaving]
cata has quit [Quit: WeeChat 4.6.3]
szkl has quit [Quit: Connection closed for inactivity]
<dorian> hey noticing something weird: is the apostrophe character special in ruby regexes?
<kmad> dorian: What's happening?
<dorian> like if i do "that's all folks".gsub(/'/, "\\'") i get "thats all folkss all folks"
dionysus69 has joined #ruby
<dorian> which, wat
<dorian> like i'm trying to escape the apostrophe obvs
<kmad> Ah, it's the replace argument. \' in the replacement refers to 'the entire matched pattern' (as do \0).
<dorian> ah, so how would i express "a literal backslash and then an apostrophe" in a pattern replacement
<kmad> You might need "\\\'" for that, but if you're simply trying to handle quotes, there may be better options available that don't require regex.
<dorian> not trying to "handle" them beyond escaping really; what this is is a little email obfuscating routine that will take something like mailto:lol@wut.biz?subject=blah%20blah%20blah and turn it into javascript:sendMail('wut.biz','lol','blah%20blah%20blah') - just need to handle the case that there's an unescaped apostrophe (note url-encoding it is not enough because the js decodes it before evaluating)
<dorian> er unescaped apostrophe in the subject
<dorian> (also note that ' is part of the `sub-delims` character class in rfc3986 and does not need to be url-encoded)
svm is now known as msv
<kmad> Wouldn't it work if you entity-encoded it, like: &quot; ?
<dorian> you would use &quot; if you were using single ticks for the attributes, like href=''
<dorian> ie not where the issue is
<kmad> I just saw you were using single quotes in the javascript call, I thought that was the issue.
<dorian> single quotes in the javascript: URI, because using standard double quotes in the html attributes
<dorian> but if the thing inside the string contains a quote, it will break the *javascript* syntax
<kmad> Ah, I see.
<dorian> so that has to be escaped
<dorian> i think i figured it out though, just using lookahead/lookbehind assertions
sarna has quit [Ping timeout: 260 seconds]
<kmad> It's weird. I don't think using lookahead/lookbehind should be at all necessary.
<dorian> agreed in principle but this is giving me a hell of a time
<kmad> Yeah, it's weird. I can't make it behave either.
<kmad> The docs here (https://ruby-doc.org/core-3.1.0/String.html#class-String-label-Substitution+Methods) suggest to use "\\\\'" in the replacement.
Guest68_ has joined #ruby
ruby[bot] has quit [Remote host closed the connection]
ruby[bot] has joined #ruby
Guest68_ has left #ruby [Textual IRC Client: www.textualapp.com]
<dorian> hah
<dorian> oh my god what an odyssey
<dorian> thanks
<kmad> Np! Btw, I said that \' referred to the entire pattern. It doesn't. It only refers to the part of the string after the match.
<dorian> yeah that was obvious from the output
<dorian> probably analogous to perl
<dorian> \` and \& and \'
<kmad> Yeah, exactly.
<dorian> although i don't think perl does the backreferences like that, just $& etc
<dorian> been a while
<kmad> Yeah. Ruby has those as well, or at least it did. I don't know if they still work.
<dorian> iirc (in perl) you aren't supposed to use them because they do global stuff
<kmad> That could be. I mostly use PCRE and not Perl itself, except in CLI one-liners. :)
<dorian> it's like a potential denial-of-resource vector iirc cause it keeps the state around; better to use captures
<kmad> Ah, that's interesting.
PauloEE has joined #ruby
<dorian> don't know if it's the same in ruby
<dorian> this is my solution: %q[that's all folks'].gsub(/\G([^\\']*(?:\\\\)*(?<!\\))'/, "\\1\\\\'")
<dorian> ie "escape all single quotes that are not already preceded by an even number of backslashes"
<dorian> er odd
<kmad> That seems like something that might break spectacularly some day.
<kmad> XD
<dorian> lol
<dorian> actually yeah that lookbehind should be a lookahead
fantazo has quit [Quit: Lost terminal]
dionysus69 has quit [Ping timeout: 260 seconds]
pastelowl has joined #ruby
TomyWork has joined #ruby
inline has quit [Quit: Leaving]
wbooze has joined #ruby
inline has joined #ruby
TomyWork has quit [Ping timeout: 252 seconds]
mange has joined #ruby
GreenResponse has quit [Quit: Leaving]