What is HTML5 Feature

Category: CSS    |    289 views    |    Add a Comment  |   

HTML5 is a specification for how the web’s core language, HTML, should be formatted and utilized to deliver text, images, multimedia, web apps, search forms, and anything else you see in your browser. In some ways, it’s mostly a core set of standards that only web developers really need to know. In other ways, it’s a major revision to how the web is put together. Not every web site will use it, but those that do will have better support across modern desktop and mobile browsers (that is, everything except Internet Explorer).

What Awesomeness can I expect from HTML5?

The big, marquee changes in HTML5 have already made some headlines, thanks to browser makers like Google, Apple, Mozilla, and others picking them up and implementing them. The shortlist:

  • Offline storage: Kind of like “Super Cookies,” but with much more space to store both one-time data and persistent app databases, like email. Actually, you can think of offline storage as something a lot like Google Gears—you just won’t need to install a plug-in to reap the benefits.
  • Canvas drawing: Sites can mark off a space on a page where interactive pictures, charts and graphs, game components, and whatever else imagination allows can be drawn directly by programming code and user interaction—no Flash or other plug-ins required. Read more…

     

Best Minify JavaScript and CSS

Category: CSS    |    2,387 views    |    1 Comment  |   

Minification is the practice of removing unnecessary characters from code to reduce its size thereby improving load times. When code is minified all comments are removed, as well as unneeded white space characters (space, newline, and tab). In the case of JavaScript, this improves response time performance because the size of the downloaded file is reduced. Two popular tools for minifying JavaScript code are JSMin and YUI Compressor. The YUI compressor can also minify CSS.

Obfuscation is an alternative optimization that can be applied to source code. It’s more complex than minification and thus more likely to generate bugs as a result of the obfuscation step itself. In a survey of ten top U.S. web sites, minification achieved a 21% size reduction versus 25% for obfuscation. Although obfuscation has a higher size reduction, minifying JavaScript is less risky.

In addition to minifying external scripts and styles, inlined <script> and < Read more…

  • No Related Post

 

Make JavaScript and CSS External

Category: CSS    |    2,279 views    |    Add a Comment  |   

Many of these performance rules deal with how external components are managed. However, before these considerations arise you should ask a more basic question: Should JavaScript and CSS be contained in external files, or inlined in the page itself?

Using external files in the real world generally produces faster pages because the JavaScript and CSS files are cached by the browser. JavaScript and CSS that are inlined in HTML documents get downloaded every time the HTML document is requested. This reduces the number of HTTP requests that are needed, but increases the size of the HTML document. On the other hand, if the JavaScript and CSS are in external files cached by the browser, the size of the HTML document is reduced without increasing the number of HTTP requests.

The key factor, then, is the frequency with which external JavaScript and CSS components are cached relative to the number of HTML documents requested. This factor, although difficult to quantify, can be gauged using various metrics. If users on your site have multiple page views per session and many of your pages re-use the same scripts and stylesheets, there is a greater potential benefit from cached external files. Read more…

  • No Related Post