- Read [Node.js, Require and Exports][rblog] and [Organize Your Code with RequireJS][rblog2]
- Fork This Gist
- Respond in your forked gist with answers to the following questions
-
In the context of Node, what is a
module?- A module in Node from my understanding, is a function that wraps other functions and basically copies/mimics the functionality and imports it into another file in order to be used as intended.
-
##Leap My code: here
-
Responder #1 (here) - This responder took largely the same approach as me but used this.isLeap vs me using a prototype method and the indentation is different.
-
Responder #2 (here) - This responder used a single line method that seems to use all the same steps that I did but could be considered less readable.
-
Responder #3 (here) - This responder took largely the same approach as me but used an && style if statement which took off the need for one of my else ifs.
-
Responder #4 (here) - This responder took a similar approach to me but used this.isLeap and did a single line return statement.
rails new <project_name> -d postgresql --skip-test-unit --skip-turbolinks --skip-spring
-d postgresqlsets up the project to use PostgreSQL--skip-test-unitskips the creation of the test directory--skip-turbolinks&--skip-springcreates a project that does not use turbolinks or spring
- In the Gemfile:
- inside of
group :development, :test:gem 'rspec-rails'bundlerails g rspec:install
gem 'capybara
- get "/artists" artists_path
- get "/artists/42" artist_path(42)
- get "/artists/42/edit" edit_artist_path(42)
- put "/artists/42" artist_path(42)
- get "/artists/new" new_artsit_path
- post "/artists" artists_path
- delete "/artists/42" artist_path(42)
- get "/stickers" stickers_path
- get "/stickers/42" sticker_path(42)
Group Member Names:
-
When are group members available to work together? What hours can each group member work individually? Are there any personal time commitments that need to be discussed?
-
How will group members communicate? How often will communication happen, and how will open lines of communication be maintained?
-
Which feature(s) does each group member want to work on? Which feature(s) does each group member not want to work on?
- Load/Reload waffle.
- Choose a card from the backlog in waffle. If we're working separately, it's best to move that card that you've chosen into ready and perhaps assign it to yourself as well.
- git checkout master
- git pull origin master
- run rspec
- Checkout a new branch and tag it with #issue_number
- Write the feature test associated with your waffle card.
- Run rspec, and make sure that there are no errors that blow up the stack (missing ends, forgetting capitalization, etc.)
- commit your feature test
- First let's read MDN HOW WEB WORKS.
- Next let's watch a few quick examples of how the internet works.
- And [how IP addresses work](https://www.youtube.com/watch?v=KFooN7Mu0IM - how IP addresses work).
- Finally let's tie these things together and watch a video about DNS - what happens when you type an address into a web browser.
This exercise is intended to help you assess your progress with the concepts and techniques we've covered during the week.
For these questions, write a short snippet of code that meets
the requirement. In cases where the question mentions a "given"
data value, use the variable given to refer to it (instead of re-writing
the information).
- What do you know about modules already? If little, what would you guess modules are all about?
- Golf and basketball both use a ball. But if you're on a basketball court and ask for "the ball," no one is going to throw you a golf ball. Why? If you were as dumb as a computer, why would a golfd ball be an acceptable response?
- You've learned about the object model and method lookups. What would the imapct be of injecting an additional ancestor into a class' lookup chain?