Anda di halaman 1dari 3

Wanna be a AngularJS Developer @ XXX.com?

Proveit.
Writeasimplequizappwiththespecbelow.Theexercisebelowshould require 1-4 days of
effort (depending on levels of detail you wish to achieve),soplanaroundthat.

Shipit.
Onceyouredone,sendusalinktotheGitHubrepoaswellastherunningapp(howyoudeploy
itisuptoyou).Wellreviewbasedonaccuracy,bestpractice,style,and...attitude.

TechnicalRequirements
1. Use
a. GitHub
b. AngularJS
c. Jasmine
d. BonuspointsforuseofHAMLandCoffeescript
2. Avoid
a. jQuery(relyonAngularJSJQLitewherepossible)
3. Organizeprojectinawaythatmakessensetoyou.
4. ProvidesufficienttestcoverageforallJavascript.

ProductRequirements
1. Allowuserto
a. register(email&password)
b. takequiz
c. submitquiz
d. viewresults
e. viewcorrectanswers
f. logout

QuizContent
1. Whichisnotanadvantageofusingaclosure?
a. Preventpollutionofglobalscope
b. Encapsulation
c. Privatepropertiesandmethods
d. Allowconditionaluseofstrictmode
2. Tocreateacolumnedlistoftwolineemailsubjectsanddatesforamasterdetailview,
whicharethemostsemanticallycorrect?
a. <div>+<span>
b. <tr>+<td>
c. <ul>+<li>
d. <p>+<br>
e. noneofthese
f. allofthese
3. Topassanarrayofstringstoafunction,youshouldnotuse...
a. fn.apply(this,stringsArray)
b. fn.call(this,stringsArray)
c. fn.bind(this,stringsArray)
4. ____and____wouldbetheHTMLtagsyouwouldusetodisplayamenuitemandits
description.
5. Given<divid=outer><divclass=inner></div></div>,whichofthesetwoisthemost
performantwaytoselecttheinnerdiv?
a. getElementById("outer").children[0]
b. getElementsByClassName("inner")[0]
6. Giventhis:
angular.module(myModule,[]).service(myService,(function(){
varmessage=Messageone!
vargetMessage=function(){
returnthis.message
}
this.message=Messagetwo!
this.getMessage=function(){returnmessage}
returnfunction(){
return{
getMessage:getMessage,
message:Messagethree!
}
}
})())

Whichmessagewillbereturnedby
injectingthisserviceandexecuting
myService.getMessage()

a. 1
b. 2
c. 3

Designrequirements

Anda mungkin juga menyukai