Вы находитесь на странице: 1из 6

FRONTEND

Pre-requisites : HTML, CSS, JavaScript


HTML:

1. What does <!Doctype html> do? Is it an HTML tag? (IMP)


Ans: NO..not an html tag

it is an instruction to the web browser about what version of HTML the


page is written in.(Doctype Declaration)
2.Followup: So if I want to tell the browser to run the page on HTML 5? What
should be done?
Ans: <!doctype html> tells the latest version. So, HTML5 will be run
automatically

2. Worked with any HTML templating engines? (Not imp)


Ans: If yes, ask what does a templating engine do?
Ans:Makes workflow easier via:
-Making it modular : think about a modular web page structured with
components that can be modified independently of each other.These components
may include a header, footer, global navigation bar (GNB), local navigation bar
and content such as articles, images, videos etc.
-Flexible Presentation
-Mass Prdocution (Reusability of code)

CSS:
1. What is the diff between classes and ids?
Ans: Ids: Start with a # when referring. Have higher priority than classes
Classes: Start with . When referring.

2. Explain CSS sprites, and how you would implement them on a page or
site.
Ans: CSS Sprites are a means of combining multiple images into a single
image file for use on a website, to help with performance. Basically, when
the individual image files are too large, it is better for us to combine them
in a single file.
Follow UP: Have you made a sprite before? (Requires knowledge of a
photo-editing software)

3. Have you used any CSS frameworks ?


Ans: The candidate shouldve used atleast one framework. Popular
frameworks include : Bootstrap, Skeleton, Foundation,Semantic UI.
FollowUp : What does a framework do?
Ans: Basically, makes design easier using pre-prepared code. (in terms of
responsivity, UI etc)
FollowUp: So if you write a code while referring to a class provided by the
framework, and use the same class name in another CSS file, which one
will the browser prefer? The framework class or your custom class?
Ans: Whichever is linked to the main HTML first.
4. Do you know how to use media queries? Will you prefer using a framework
or will you prefer using media queries to make a professional responsive
site?
Ans: Should know media queries. Reject if not.
/if prefers media queries, ask why, when frameworks can be easily
implemented?
/if prefers frameworks, ask why, because frameworks are pre-prepared
and media queries will give you exactly what you want
/best ans: that both, frameworks for ease, and media queries if you want
to do something specific.

5. How is responsive design different from adaptive design?(IMP)


Adaptive design uses distinct screen sizes to deliver(done usually by
media queries)
Responsive design uses fluid grids and adjusts to any screensize

JavaScript(IMP)
1. How do animations in CSS differ from that in JS performance wise?
Differ on the type of animation :
-Use CSS animations for simpler one-shot transitions, like toggling UI
element states.
-Use JavaScript animations when you want to have advanced eff ects like
bouncing, stop, pause, rewind or slow-down.

2. What is AJAX?

Ajax is abbreviated as Asynchronous Javascript and XML. It is new technique used


to create better, faster and more interactive web systems or applications. Ajax uses
asynchronous data transfer between the Browser and the web server.

3. What are the advantages of Ajax?


Following are the advantages of Ajax:
Bandwidth utilization It saves memory when the data is fetched from the
same page.
More interactive
Speeder retrieval of data
4. Difference between JavaScript and AJAX?
AJAX

Javascript

AJAX sends request to the server and does not wait for the
response. It performs other operations on the page during

JavaScript make a request to the server and waits for

that time

response

AJAX does not require the page to refresh for downloading

JavaScript manages and controls a Web page after being

the whole page

downloaded

AJAX minimizes the overload on the server since the script

JavaScript posts a request that updates the script every

needs to request once

time

5. What is MVC? Any frameworks you are familiar with?


As the UI gets more and more complex we need some good ways to keep it
more and more maintainable and reusable, and Some MVC frameworks for
javascript have been widely adopted lately and it's a good plus if you have
already used before and knows what's the benefits of them. The most famous

MVC frameworks arebackbone.js and angular.js, it's hard to not hear about
them.

There are many advantages in using these frameworks, I can point out some of
them:

Organization: Forces your webapp to follow a well structured pattern;

Maintainable: With organization comes an easy to maintain code;

UI Binding: Some frameworks allow you to do that. So everytime your model


changes, the view reflects it and vice-versa;

Decoupled client: MVC frameworks like backbone.js incentivise you to use


REST API's though their urlRoot attribute in their Models;

Reusable components: Create reusable visual components;

Single-page apps: Build single-page apps with Ajax requests;

Friendly URL's: Native support for client-side url mapping;


6. So what is DOM?
The Document Object Model (DOM) is a programming API for HTML and XML
documents. It defines the logical structure of documents and the way a
document is accessed and manipulated. In the DOM specification, the term
"document" is used in the broad sense - increasingly, XML is being used as a
way of representing many different kinds of information that may be stored in
diverse systems, and much of this would traditionally be seen as data rather
than as documents. Nevertheless, XML presents this data as documents, and
the DOM may be used to manage this data.

BACKEND
Prerequisites: Python/NodeJs/Ruby/php
Query Languages:SQL/MongoDB
General frameworks(should know one):
Python : Django/Flask/Bottle
Ruby: Rails/Sinatra
NodeJS: Express JS
General Qs:
Ask why the language of choice and why?
-php: not secure/ slow
-ruby:not fast
-python:not fast
-nodejs: thumbs up (Y)
__________________________________
What is MVC? Model/Views/Controls : Define each of the M /V/ C
Ans: Model: Your activerecord(keyword)
Views:What you are going to see on the site
Controls: The functions that defines how the object behaves
----------------------------------------------------What Is a session?

"Session" is the term used to refer to a user's time browsing a web site. It's meant to
represent the time between their first arrival at a page in the site until the time they stop
using the site. In practice, it's impossible to know when the user is done with the site. In
most servers there's a timeout that automatically ends a session unless another page is

requested by the same user.

Describe the difference between a cookie, sessionStorage and localStorage in


terms of capabilities( IMP)
Ans: In terms of capabilities, cookies only allow you to store strings. sessionStorage and
localStorage allow you to store JavaScript primitives but not Objects or Arrays (it is possible
to JSON serialise them to store them using the APIs). Session storage will generally allow
you to store any primitives or objects supported by your Server Side language/framework.
What is the difference between JSON and REST?

RESTful web-services use standard URIs and methods to make calls to the webservice.
When you request a URI, it returns the representation of an object, that you can then
perform operations upon (e.g. GET, PUT, POST, DELETE). You are not limited to picking
XML to represent data, you could pick anything really (JSON included)

JSON: JSON and XML, are functionally equivalent, and either could be chosen. XML is
thought of as being too verbose, and harder to parse, so many-a-times, data is more
adequately represented using JSON. (E.g. serialization)

Can you return a JSON object using SQL?


No, we use NoSQL DBs instead. Example:MongoDB

Вам также может понравиться