JavaScript / Programmings / Technologies

An Introduction to Web Workers

Overview Browsers use single thread for JavaScript and UI. So synchronous JavaScript calls will block this thread, thus rendering will be blocked. For example, if our website needs to do UI events, fetch and process large amount of API data and manipulate DOM. It is not possible do all these simultaneously since the script execution … Continue reading

API / JavaScript / Programmings / Technologies

Getting Started with IndexedDB

Overview IndexedDB  is an API for storing significant amounts of structured data in user’s browser. It helps to do high performance  searches using indexes. The data stored in IndexedDB is persistent and work in online and offline.  It provides both a synchronous and an asynchronous API. In practice, however, all current implementations are asynchronous, and … Continue reading

JavaScript / Programmings

Getting Started With Handlebars.js – Templating Engine for JavaScript.

  Handlebars.js is a Logic-less template engine for JavaScript. When we need an application with frequently updating view, template engine has to play big role. It keep you HTML pages simple, clean and decouples from logic based JavaScript files. Also reduce effort by reducing loops with native JavaScript. It is also possible to precompile your … Continue reading

JavaScript / jQuery / PHP / Programmings / Technologies

Image preview before upload file

We can preview the uploaded image easily with jQuery or JavaScript before actual upload of file. Just Follow these Steps HTML Code <form id=”Imgfrm”> <input id=”imgfile” type=”file” /> <img id=”preview” src=”#” alt=”your image” />< /form> Then use following jQuery Code (You can use pure JavaScript also) $(“#imgfile”).change(function(){ if (this.files && this.files[0]) { var reader = … Continue reading