Linked In | Front End Position | California | Sept 13
Anonymous User
1073

Want to share my Phone screen interview. Only focussed on Javascript.

  1. Explain Event Bubbling

  2. What is the output for below code and how will you correct it

function bar(){
return a;
}

this.baz = function() {
return a;
};
};

Foo.prototype = {
this.biz: function() {
return this.a;
},
};

const f = new Foo(7);

f.bar(); //
f.baz(); //
f.biz(); //

  1. What are CSS Processors (didnt remember exact question)
  2. Implement scrolling event in JS and how will you load data from API on scroll like in Linkedin Feed.

/**

  • API Docs

  • /posts?page=0 => [{id: 1, title: 'Post 1'}, {id: 2, title: 'Post 2'}, {id: 3, title: 'Post 3'}, N...]
  • /posts?page=1 => [{id: 4, title: 'Post 4'}, {id: 5, title: 'Post 5'}, {id: 6, title: 'Post 6'}, N...]
  • /posts?page=N => [N...]
    */

// HTML
// ---------

    // JS
    // ---------
    $(window).on('scroll', scrollHandler);

    Comments (1)