Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Rubinai ant bėgių
Search
Domas Bitvinskas
November 30, 2013
Programming
1.2k
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Rubinai ant bėgių
A brief sweet intro into Ruby on Rails.
Domas Bitvinskas
November 30, 2013
More Decks by Domas Bitvinskas
See All by Domas Bitvinskas
3 cool AI things
nedomas
0
620
Apollo & GraphQL: What we learned building a multi-platform chat app
nedomas
1
440
Best kept secrets for 2019: GraphQL + Prisma
nedomas
1
110
Tensorflow.js ir web ateitis
nedomas
1
230
Hack the Open Source Growth
nedomas
1
200
Market your Open Source or kill it
nedomas
1
1k
Ruby on Rails is dead
nedomas
2
1.3k
Why does Ruby own the startup world?
nedomas
0
740
Rockstars and Productivity
nedomas
1
1k
Other Decks in Programming
See All in Programming
Seven New Principles of Software Engineering
yegor256
0
360
作れる、でも消せるか?──安全に「枯らして消す」機能削除術 / Drain, Then Delete
chobishiba
2
1.2k
エージェントを使い続けるためのメタワーク / Meta-work for keeping using the agent
rkaga
6
2k
個人開発者よ、Honoを使え(おじさんver)
tanahiro2010
2
290
When benchmarks go bad - what I learned from measuring performance wrong
hollycummins
0
250
Kotlinize Is Not Just Converting to Kotlin
chigichan24
1
200
sbt 2.0: takeoff
eed3si9n
0
170
私なりのハーネスエンジニアリング ~独自の言語処理系の開発を通して~
seosoft
0
110
AI時代のシニアエンジニアとは
yosuke_furukawa
PRO
12
10k
あなたの await、OS まで届いてる? strace で覗く JavaScript の非同期
hasutosasaki
1
1.6k
Lambda durable functionsでHuman in the Loopを楽に…楽に……
har1101
2
210
Compiling a real-world CLI tool to native with Static Hermes
tmikov2023
0
130
Featured
See All Featured
Test your architecture with Archunit
thirion
2
2.5k
We Are The Robots
honzajavorek
0
410
Rebuilding a faster, lazier Slack
samanthasiow
85
9.7k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
31k
Lightning talk: Run Django tests with GitHub Actions
sabderemane
0
300
A better future with KSS
kneath
240
18k
Crafting Experiences
bethany
1
390
The SEO identity crisis: Don't let AI make you average
varn
0
610
Agile that works and the tools we love
rasmusluckow
331
22k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
123
22k
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.6k
My Coaching Mixtape
mlcsv
0
370
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