Models | Examples |
---|---|
Display ads | Yahoo! |
Search ads |
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
class Project < AR::B | |
has_many :comments, :as => :commentable | |
end | |
class Comment < AR::B | |
belongs_to :commentable | |
end | |
- form_for :project do |project_form| | |
/ fields_for :comment doesn't work :-S | |
- project_form.fields_for :comment_attributes do |comment_form| |
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
class App extends React.Component { | |
startWondering = (e) => { | |
this.setState({ feeling: 'wondering' }) | |
} | |
render() { | |
const { feeling } = this.state | |
const { feeling: initialFeeling } = this.__proto__.state | |
I hereby claim:
- I am some1else on github.
- I am some1else (https://keybase.io/some1else) on keybase.
- I have a public key ASCb_P_uA3882AjVcsGXLBU8PUatwAJD1OGcOSEZsqJdago
To claim this, I am signing this object:
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
#!/bin/sh | |
start_time=$(date +%s) | |
trap 'end_time=$(date +%s); echo "\n *** Completed in: $((end_time - start_time)) seconds\n"' EXIT | |
echo "\033[35m\n *** Build & deploy to production\n\033[0m" | |
# Guards | |
cd app-frontend |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title><%= request.host %></title> | |
<%= csrf_meta_tags %> | |
<%= csp_meta_tag %> | |
<%- unless ENV['index_js'].present? and ENV['index_css'].present? | |
Dir.glob("public/static/js/*.js").each do |file_path| |