Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <ul> <li><p>Q: <code>position: absolute</code> positions an element absolutely in relation to <em>what</em>?</p> <p>A: Closest positioned container, even if it is relatively positioned. A lot of people seem to believe that the document body is always the answer here</p></li> <li><p>Q: Other than <code>z-index</code>, what factors affect how elements stack on top of each other, when they overlap?</p> <p>A: The order in which they appear in the DOM, and, critically, absolutely positioned elements will always appear on top of elements that are not absolutely positioned. For cross-browser compatibility points, the interviewee might also point out that in IE6, certain elements such as the <code>select</code> will be visible above all others. This is also common with embedded elements, such as flash files, in a lot of browsers.</p></li> <li><p>Q: What is a block element, as opposed to an inline element? What can you say about the two types' relative appearance?</p> <p>A: An element that formats an entire paragraph, rather than a span of text. Examples are <code>h1</code>, <code>div</code>, <code>p</code>. A block element will by default have some margin around it, and will assume 100% width unless specified, or floated. An inline element cannot have a width assigned.</p></li> <li><p>Q: How is an element, and surrounding elements, affected by floating?</p> <p>A: A block element will not allocate more width than it absolutely requires. Sibling after the element will appear side by side, rather than below, if there is available space to allow for it. <em>The element will not allocate any height in its container unless it is <code>clear</code>ed</em>. An alternative to this Q would be to simply ask what <code>clear</code> does. This is the main thing I would want from the answer, as I've noticed a lot of people not using <code>clear</code> in an accurate manner, and it can lead to solving simple problems in a very messy manner. </p></li> </ul> <p>I'd also ask the interviewee to explain the box model.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload