githubnext / githubnext/monaspace
Add Ruby code preview to website
- Lingua principale
- Shell
- Stelle
- 19.6k
- Fork
- 322
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
I want to see how it looks with Ruby source code.

Feel free to use this snippet:
```rb
class Person
attr_accessor :name, :age
def initialize(name, age)
@name = name
@age += age
end
def ==(other)
@name == other.name && @age == other.age
end
def <=>(other)
@age <=> other.age
end
def !~(other)
@name !~ other.name || @age != other.age
end
def =~(other)
@name =~ other.name && @age == other.age
end
def <<(other)
@name << other.name
end
def >>(other)
@age >> other.age
end
def **(other)
@age ** other.age
end
def &&(other)
@name && other.name && @age && other.age
end
def ||(other)
@name || other.name || @age || other.age
end
end
alice = Person.new("Alice", 30)
bob = Person.new("Bob", 35)
puts alice == bob # => false
puts alice <=> bob # => -1
puts alice !~ bob # => true
puts alice =~ bob # => false
puts alice << bob # => "AliceBob"
puts alice >> bob # => 30
puts alice ** bob # => 9000000000000000
puts alice && bob # => true
puts alice || bob # => true
```
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Start by locating the website code that assembles the existing code previews and compare how other source languages are represented. Add the supplied Ruby snippet where appropriate, then verify that the website renders the Ruby source correctly.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- ruby
- Ambito
- web-dev
- Tipo di issue
- Funzionalità
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 45/100