This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# sample/sample_app.rb | |
require 'sinatra' | |
require 'pry' | |
# We us "classic" mode where you don't actually see the class | |
# inheriting from Sinatra::Base and you don't start the app with | |
# rackup. This makes the object structure less obvious but lets | |
# Sinatra do more of the behind-the-scenes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'sinatra' # simple web framework | |
require 'data_mapper' # metagem, requires common plugins too. | |
# need to install dm-sqlite-adapter | |
DataMapper.setup(:default, "sqlite3://#{settings.root}/dictionary.sqlite3") | |
set :port, 4000 # port and binding set for Nitrous.io debugging | |
set :bind, '0.0.0.0' | |
# You don't have to define the instance variables, DataMapper does that. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'sinatra' | |
require 'data_mapper' | |
DataMapper.setup(:default, "sqlite3://#{settings.root}/dictionary.sqlite3") | |
set :port, 4000 | |
set :bind, '0.0.0.0' | |
class Entry | |
include DataMapper::Resource | |
property :id, Serial | |
property :word, String |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
v/zxkcmv/zxclmv/.zxc,vm/xzc.,vm/xzcv,mxzc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>JavaScript & jQuery Example</title> | |
<!-- | |
We put the styles here just to keep the assignment all in one file. | |
Normally they go in separate files. | |
--> | |
<style type="text/css"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script> | |
<style> | |
body { | |
font-family: "Open Sans", sans-serif; | |
} | |
</style> | |
</head> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# this is a comment | |
# | |
# "mkdir ~/bin" makes a "bin" folder in your home folder. this is a good place to put your own programs | |
# "rm ~/bin/subl" removes any "subl" command that you might already have | |
# 'ln -s "/Appli...."' links "subl" to the app in your Applications folder | |
# cut and paste these commands into your terminal shell: | |
mkdir ~/bin | |
rm ~/bin/subl | |
ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" ~/bin/subl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script> | |
<style> | |
body { | |
font-family: "Open Sans", sans-serif; | |
} | |
textarea { | |
height: 5em; | |
width: 40em; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JavaScript Immersion Retrospective 20150902 | |
* Please feel free to edit and add to this etherpad. You can remain anonymous if you wish. | |
* If you prefer, you can send us anonymous feedback at https://docs.google.com/forms/d/1Ix-5grMUdFm00ilb4_EqCLUd5jfJaOC900r-kfUHjqk/viewform | |
* And, please contact Kristina, Cris, or Collaine if you have concerns that you would prefer to discuss in person. | |
We will ask everybody to contribute something in both of the following areas. When it's your turn, if you agree with something that's already here, that's great. Please +1 the existing comment and then also tell us your perspective. | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JavaScript Evening Retrospective 2015/09/02 | |
* Please feel free to edit and add to this etherpad. You can remain anonymous if you wish. | |
* If you prefer, you can send us anonymous feedback at https://docs.google.com/forms/d/1Ix-5grMUdFm00ilb4_EqCLUd5jfJaOC900r-kfUHjqk/viewform | |
* And, please contact Kristina, Cris, or Collaine if you have concerns that you would prefer to discuss in person. | |
We will ask everybody to contribute something in both of the following areas. When it's your turn, if you agree with something that's already here, that's great. Please +1 the existing comment and then also tell us your perspective. | |
What is working well? |
OlderNewer