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
import React, { useState } from 'react'; | |
function App() { | |
const [ score, setScore ] = useState(0); | |
const [ message, setMessage ] = useState('Welcome!'); | |
return ( | |
<div className="App"> | |
<header className="App-header"> | |
<h1>{ message }</h1> |
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
import React, { useState } from 'react'; | |
function App() { | |
const [ score, setScore ] = useState(0); | |
const [ message, setMessage ] = useState('Welcome!'); | |
return ( | |
<div className="App"> | |
<header className="App-header"> | |
<h1>{ message }</h1> |
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
.selector { | |
display: block; | |
} |
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
git for-each-ref --sort=-committerdate refs/heads/ --color --format="%(HEAD)%(color:bold)%(refname:short)%(color:reset);%(color:green)%(committerdate:relative)%(color:reset);%(committerdate:format:'%m/%d/%Y\ %H:%M');%(color:cyan)%(authorname)%(color:reset);%(color:yellow)%(objectname:short)%(color:reset) %(color:italic)%(contents:subject)%(color:reset)" | column -t -s ";" |
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
#Model | |
@user.should have(1).error_on(:username) # Checks whether there is an error in username | |
@user.errors[:username].should include("can't be blank") # check for the error message | |
#Rendering | |
response.should render_template(:index) | |
#Redirecting | |
response.should redirect_to(movies_path) |
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
@mixin adaptive-classes { | |
@content; | |
&--sm, | |
&--sm-only { | |
@include small { @content; } | |
} | |
&--sm-up { | |
@include small-up { @content; } |
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
//------------------------------------------------------------------------------------------------------------------ | |
// YOUR CODE: Create your Zoo "object literal" and Animal "constructor" and "prototypes" here. | |
//------------------------------------------------------------------------------------------------------------------ | |
//------------------------------------------------------------------------------------------------------------------ | |
// DRIVER CODE: Do **NOT** change anything below this point. Your task is to implement code above to make this work. | |
//------------------------------------------------------------------------------------------------------------------ |
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
//------------------------------------------------------------------------------------------------------------------ | |
// YOUR CODE: Create your Zoo "object literal" and Animal "constructor" and "prototypes" here. | |
//------------------------------------------------------------------------------------------------------------------ | |
//------------------------------------------------------------------------------------------------------------------ | |
// DRIVER CODE: Do **NOT** change anything below this point. Your task is to implement code above to make this work. | |
//------------------------------------------------------------------------------------------------------------------ |
- Download this application skeleton.
- Convert the app to use AJAX.
- Add any files you changed to your gist and submit your code.
NewerOlder