Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Rubinai ant bėgių
Search
Domas Bitvinskas
November 30, 2013
Programming
1
1.1k
Rubinai ant bėgių
A brief sweet intro into Ruby on Rails.
Domas Bitvinskas
November 30, 2013
Tweet
Share
More Decks by Domas Bitvinskas
See All by Domas Bitvinskas
3 cool AI things
nedomas
0
460
Apollo & GraphQL: What we learned building a multi-platform chat app
nedomas
1
330
Best kept secrets for 2019: GraphQL + Prisma
nedomas
1
83
Tensorflow.js ir web ateitis
nedomas
1
180
Hack the Open Source Growth
nedomas
1
140
Market your Open Source or kill it
nedomas
1
990
Ruby on Rails is dead
nedomas
2
1.2k
Why does Ruby own the startup world?
nedomas
0
680
Rockstars and Productivity
nedomas
1
980
Other Decks in Programming
See All in Programming
Swift Concurrency - 状態監視の罠
objectiveaudio
2
480
エンジニアとして高みを目指す、 利益を生み出す設計の考え方 / design-for-profit
minodriven
23
12k
Signals & Resource API in Angular: 3 Effective Rules for Your Architecture @BASTA 2025 in Mainz
manfredsteyer
PRO
0
110
Back to the Future: Let me tell you about the ACP protocol
terhechte
0
130
CSC509 Lecture 03
javiergs
PRO
0
330
Building, Deploying, and Monitoring Ruby Web Applications with Falcon (Kaigi on Rails 2025)
ioquatix
3
1k
dynamic!
moro
9
6.8k
Railsだからできる 例外業務に禍根を残さない 設定設計パターン
ei_ei_eiichi
0
370
なぜあの開発者はDevRelに伴走し続けるのか / Why Does That Developer Keep Running Alongside DevRel?
nrslib
3
380
タスクの特性や不確実性に応じた最適な作業スタイルの選択(ペアプロ・モブプロ・ソロプロ)と実践 / Optimal Work Style Selection: Pair, Mob, or Solo Programming.
honyanya
3
140
GitHub Actions × AWS OIDC連携の仕組みと経緯を理解する
ota1022
0
240
2分台で1500examples完走!爆速CIを支える環境構築術 - Kaigi on Rails 2025
falcon8823
3
3.4k
Featured
See All Featured
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
657
61k
Raft: Consensus for Rubyists
vanstee
139
7.1k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
114
20k
Documentation Writing (for coders)
carmenintech
75
5k
Navigating Team Friction
lara
189
15k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
667
120k
Into the Great Unknown - MozCon
thekraken
40
2.1k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
231
53k
Optimizing for Happiness
mojombo
379
70k
We Have a Design System, Now What?
morganepeng
53
7.8k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.4k
Product Roadmaps are Hard
iamctodd
PRO
54
11k
Transcript
Rubinai ant bėgių
DOMAS BITVINSKAS domasbitvinskas.com @Nedomas
kodėl?
None
None
None
<HTML>
! ! ! ! ! <h1>F-18 jet fighter with Ruby</h1>
<html> <head> <title>Talks</title> </head> <body> <h1>F-18 jet fighter with Ruby</h1>
</body> </html>
! <h1>The Kids Aren’t Alright on TODAY</h1>
<h1>The Kids Aren’t Alright on TODAY</h1> ! ! ! <h1>The
Kids Aren’t Alright on 2013-11-30</h1> PROGRAMA, GENERUOJANTI HTML
<h1>The Kids Aren’t Alright on TODAY</h1> ! ! ! <h1>The
Kids Aren’t Alright on 2013-11-30</h1> SERVERIS
Ruby Rails HTML karkasas
konfigūracija
struktūra app bin config lib log public test
struktūra app bin config lib log public test
struktūra app … models views controllers bin config
struktūra app … models views controllers bin config M V
C
None
Controller View Model
http://todoapp.com /todos SERVERIS PUSLAPIS
PUSLAPIS /todos todos/index.html.erb Todo TodosController View Model Controller index Veiksmas
PUSLAPIS /todos/index todos/index.html.erb Todo TodosController View Model Controller index Veiksmas
None
None
None
None
None
rails new server
rails new server generate
rails generate scaffold Todo name:string on_date:date done:boolean
rake db:migrate
None
None
None
None
None
! <h1>Listing todos</h1> … <tr> <td>Launch the spaceship</td> <td>2015-07-24</td> …
</tr> … HTML
app/views/index.html.erb <h1>Listing todos</h1> <% @todos.each do |todo| %> <tr> <td><%=
todo.name %></td> <td><%= todo.on_date %></td> … </tr> <% end %> … RUBY/ERB
app/controllers/todos_controller.rb class TodosController … def index @todos = Todo.all end
… end RUBY
Užduotis
Sugeneruokite aplikaciją ingredientams. Ingredientas turės: • pavadinimą - name •
kainą - price • galiojimo datą - good_till • suvalgytas - eaten ! Pavyzdys: rails new todo_app cd todo_app rails server rails generate scaffold Todo name:string on_date:date done:boolean rake db:migrate TIPAI: string, float, integer, date, datetime, boolean