-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathchapter9.html
More file actions
55 lines (46 loc) · 2.7 KB
/
chapter9.html
File metadata and controls
55 lines (46 loc) · 2.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<!doctype html>
<html>
<head>
<title>Intermediate Ruby</title>
<meta charset="utf-8">
</head>
<body>
<div>
<h1>Day 9</h1>
<h2>Sinatra with MongoDB</h2>
<h3>What's Sinatra?</h3>
<p>Sinatra keeps a minimal feature set, leaving developers to use the tools that best suit them and their application. Unlike Rails, there's no enforcement of concepts like MVC or REST in Sinatra.</p>
<p>It doesn't assume much about your application, apart from that:</p>
<ul>
<li>it will be written in the Ruby programming language</li>
<li>it will have URLs</li>
</ul>
<p>Sinatra itself provides just a minimal layer on top of the HTTP protocol. Sinatra rides on Rack.</p>
<h3>Create a folder on your hard disk</h3>
<p>Create a folder <code>sinatraapp</code>. This is where we will store our Sinatra app.</p>
<h3>Install Sinatra</h3>
<p>The simplest way to obtain Sinatra is through Rubygems.</p>
<p>In the folder <code>sinatraapp</code>, open a command window and type:</p>
<pre>$ gem install sinatra
</pre>
<p>WIP...</p>
<h2>References</h2>
<ul>
<li><a href="http://rubylearning.com/blog/using-git-github-ebook/">http://rubylearning.com/blog/using-git-github-ebook/</a></li>
<li><a href="http://learningwebdesign.com/">http://learningwebdesign.com/</a></li>
<li><a href="http://www.html-5-tutorial.com/">http://www.html-5-tutorial.com/</a></li>
<li><a href="http://www.w3schools.com/html/html_primary.asp">http://www.w3schools.com/html/html_primary.asp</a></li>
<li><a href="http://www.cssbasics.com/">http://www.cssbasics.com/</a></li>
<li><a href="http://www.w3schools.com/js/">http://www.w3schools.com/js/</a></li>
<li><a href="http://blog.segment7.net/2010/11/15/how-to-name-gems">http://blog.segment7.net/2010/11/15/how-to-name-gems</a></li>
<li><a href="http://rubylearning.com/blog/2010/10/06/gem-sawyer-modern-day-ruby-warrior/">http://rubylearning.com/blog/2010/10/06/gem-sawyer-modern-day-ruby-warrior/</a></li>
<li><a href="http://guides.rubygems.org/make-your-own-gem/">http://guides.rubygems.org/make-your-own-gem/</a></li>
<li><a href="http://devcenter.heroku.com/articles/static-sites-on-heroku">http://devcenter.heroku.com/articles/static-sites-on-heroku</a></li>
<li><a href="http://www.w3schools.com/json/default.asp">http://www.w3schools.com/json/default.asp</a></li>
<li><a href="https://github.com/karlseguin/the-little-mongodb-book">https://github.com/karlseguin/the-little-mongodb-book</a></li>
<li><a href="http://rubylearning.com/blog/2010/12/21/being-awesome-with-the-mongodb-ruby-driver/">http://rubylearning.com/blog/2010/12/21/being-awesome-with-the-mongodb-ruby-driver/</a></li>
<li><a href="http://api.mongodb.org/ruby/current/file.TUTORIAL.html">http://api.mongodb.org/ruby/current/file.TUTORIAL.html</a></li>
</ul>
</div>
</body>
</html>