-
Notifications
You must be signed in to change notification settings - Fork 83
finished testing #30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
toChaim
wants to merge
25
commits into
rithmschool:master
Choose a base branch
from
toChaim:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
finished testing #30
Changes from 24 commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
993239d
finished testing
toChaim 31b4be4
fix some tests and my progress so far.
toChaim 4fc875b
a little more done.
toChaim f401746
fix sort on mergeArrays and remove unesercery arguments from callback…
toChaim 551ac19
inRange done
toChaim de0972b
refactor and improve inRange. Now it the non inclusive end is right f…
toChaim 8166895
finish lodash
toChaim 14ac495
game working, responsive working.
toChaim 32904c3
2015 exersiexercises
toChaim ba3afd8
half finished.
toChaim 633ce47
functioning is fine. styleing needs work.
toChaim 839272f
minore improvments.
toChaim b65ff9d
fix favoriets filter bug
toChaim 9db7da1
first commit on new progject
toChaim acf4726
working on using login
toChaim fe30029
got get of favoriets array working. improve login click.
toChaim 380ef76
start on callApplyBind problems
toChaim fb38d6d
finished tests for guessingGame and passed tests.
toChaim 05e9cce
finish part 1 and 2 original.
toChaim 15056d5
Merge branch 'master' of https://github.com/rithmschool/intermediate_…
toChaim f4d98df
finish part 1 & 2
toChaim ed8a7e3
tic,tac,toe working
toChaim fd0df58
refactoring tic tac toe
toChaim c70ee42
fix message. Calling myself done.
toChaim 854a393
refactor hacker snooze. Almost Done
toChaim File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file not shown.
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| .row{ | ||
| margin-bottom: 30px; | ||
| } | ||
| .glyphicon{ | ||
| margin: 5px; | ||
| } | ||
| .hideNoLogin{ | ||
| visibility: hidden; | ||
| } |
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| <!DOCTYPE html> | ||
| <html lang="en"> | ||
| <head> | ||
| <meta charset="UTF-8"> | ||
| <title>Linker</title> | ||
| <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous"> | ||
| <link rel="stylesheet" href="https://bootswatch.com/readable/bootstrap.min.css"> | ||
| <link rel="stylesheet" href="index.css"> | ||
| </head> | ||
| <body> | ||
| <div class="container"> | ||
| <div class="row alert-warning header"> | ||
| <div class="col col-xs-2">icon</div> | ||
| <div class="col col-xs-8"><ul class="list-inline"> | ||
| <li class="list-inline-item"><a id="favor-link" class="" href="#">Favoriets</a></li> | ||
| </ul></div> | ||
| <div class="col col-xs-2"><ul class="list-inline"> | ||
| <li class="list-inline-item"><a id="login-link" class="" href="#">Login</a></li> | ||
| </ul></div> | ||
| </div> | ||
| <div class="row hidden" id="login-form"> | ||
| <form class="col-xs-offset-6 col col-xs-6 " action="#"> | ||
| <div class="row input-group"> | ||
| <label class="input-group-addon control-label" for="inp-email">Email</label> | ||
| <input type="email" class="form-control" name="inp-title" id="inp-email" value= "[email protected]" required> | ||
| </div> | ||
| <div class="row input-group"> | ||
| <label class="input-group-addon" for="inp-password">Password</label> | ||
| <input type="password" name="inp-password" class="form-control" id="inp-password" value="password" required> | ||
| </div> | ||
| <div class="col-xs-offset-2 col-xs-2 input-group"> | ||
| <button type="submit" id="login-btn" class="btn-warning">Login</button> | ||
| </div> | ||
| </form> | ||
| </div> | ||
| <div class="row"> | ||
| <ol id="links"> | ||
| <li>This should be removed</li> | ||
| </ol> | ||
| </div> | ||
| </div> | ||
| <script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-3.2.1.min.js"></script> | ||
| <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script> | ||
| <script type="text/javascript" src="index.js"></script> | ||
| </body> | ||
| </html> |
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,62 @@ | ||
| $(document).ready(function(){ | ||
| //variables | ||
| var auth_token; | ||
|
|
||
| //imeadiat calls | ||
| getTop().then(function(data){ | ||
| debugger | ||
| }) | ||
|
|
||
| //click functions | ||
|
|
||
| //functions | ||
| function getTop(){ | ||
| return $.get('https://hacker-news.firebaseio.com/v0/' | ||
| + 'topstories.json?print=pretty') | ||
| .then(function(topstories){ | ||
| console.log(topstories); | ||
| return Promise.all(topstories.slice(0,50).map(function(v,i){ | ||
| return $.get( | ||
| `https://hacker-news.firebaseio.com/v0/' | ||
| + 'item/${topstories[i]}.json?print=pretty`) | ||
| })); | ||
| }) | ||
| .fail(function(err){ | ||
| console.warn(err); | ||
| return err; | ||
| }); | ||
|
|
||
| } | ||
|
|
||
| function getFav() { | ||
| return $.ajax({ | ||
| method: "GET", | ||
| headers: { | ||
| "Authorization": auth_token, | ||
| }, | ||
| 'url': 'https://hn-favorites.herokuapp.com/stories.json', | ||
| }) | ||
|
|
||
| } | ||
|
|
||
| function getLogin(email, password){ | ||
| $.ajax({ | ||
| method: "POST", | ||
| headers: { | ||
| "Content-Type": "application/json" | ||
| }, | ||
| url: "https://hn-favorites.herokuapp.com/login", | ||
| data: JSON.stringify({ | ||
| 'email': email, | ||
| 'password': password | ||
| }) | ||
| }).then(function(data) { | ||
| localStorage.setItem('auth_token', data.auth_token); | ||
| auth_token = data.auth_token; | ||
| console.log(data.auth_token); | ||
| }) | ||
|
|
||
|
|
||
| } | ||
|
|
||
| }); | ||
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| "use strict" | ||
|
|
||
| function sumEvenArguments(){ | ||
| var arr = [].slice.call(arguments); | ||
| return arr.reduce( | ||
| function(t, v){ | ||
| if(v % 2 === 0) { return t+v; } | ||
| else { return t;} | ||
| },0); | ||
| } | ||
|
|
||
| function arrayFrom(obj){ | ||
| return [].slice.call(obj); | ||
| //return Array.prototype.slice.call(obj); | ||
| /* | ||
| var arr = []; | ||
|
|
||
| for(let i = 0; i < obj.length; i++){ | ||
| arr.push(obj[i]); | ||
| } | ||
|
|
||
| return arr; | ||
| */ | ||
| } | ||
|
|
||
| function invokeMax(fn, max){ | ||
| var count = 0; | ||
|
|
||
| return function(){ | ||
| if(++count > max) return `Maxed Out!`; | ||
| var arr = [].slice.call(arguments); | ||
|
|
||
| return fn.apply(this, arr); | ||
| }; | ||
|
|
||
| } | ||
|
|
||
| function guessingGame(amount){ | ||
| var count = 0; | ||
| var answer = Math.floor(Math.random() * 11); | ||
|
|
||
| return function(guess){ | ||
| if(count++ === amount) { return `No more guesses the answer was ${answer}`; } | ||
| else if(count > amount) { return `You are all done playing!`; } | ||
| else if(answer > guess){ return "You're too low!"; } | ||
| else if(answer < guess){ return "You're too high!"; } | ||
| else if(answer === guess){ return "You got it!"; } | ||
| } | ||
|
|
||
| } |
This file contains hidden or 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 file contains hidden or 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 file contains hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like you mixed single quotes and back tics. I'm not sure what that does actually.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you want to use two string templates: