aristotelesbr

@aristotelesbr@ruby.social
55 Followers
87 Following
240 Posts
Desenvolvedor, filósofo do ruby, apaixonado pelo cosmos, resolvo problemas e faço coisas rodarem na web. Canhoto após adulto. 👾
Abouthttps://aristotelescoutinho.com.br
Você não é maior porque tem mais, só tá mais longe de lembrar de onde veio.
Here are two elegant approaches to extract values: one assigning at match time and another using pattern matching from Ruby version 3.2. Tks Nobu and Jerimy Evans. 🚀 #Ruby #Coding #PatternMatching
Starting from version 3.2, pattern matching in #Ruby has been refined. For the example I shared, the correct match is for 3 elements, not 4, using the MatchData#deconstruct method. Thus, I don't consider this approach valid. 🧶
why is it not possible to define methods as "|>" in #Ruby ? 😶

Unleash the power of pattern matching. 😎

#Ruby #tips #coding

[en] How to prevent direct access to internal components and make contracts clearer and more explicit. 🤯

[pt-BR] Como prevenir acesso direto a componentes internos e tornar contratos mais claro e explícitos. 🤯

#Ruby #codinglife #coding #RubyTips

GitHub - aristotelesbr/lsd: A modern alternative to the ls command inspired by Nushell's output, written in Ruby.

A modern alternative to the ls command inspired by Nushell's output, written in Ruby. - aristotelesbr/lsd

GitHub

Não tenho certeza se isso deveria acontecer.

#ruby #debug #coding

[pt-BR] Não sei se esse erro deveria acontecer, mas encontrei uma forma de 'contornar' isso para escrever meus testes. Alguém sabe explicar?

[en] I’m not sure if this error is supposed to happen, but I found a way to 'work around' it to write my tests.

🤷

#Ruby

Diquinha rápida pra modificar metodos de classe core sem afetar o scopo global.

#ruby #tips