Containers give you a way to run you application in a controlled environment, isolated from other applications running on the machine and from the underlying infrastructure. It means that when you go to deploy, all the dependencies are published together. So you can finally say, "It worked on my machine" and mean it. All the... Continue Reading →
Object JavaScript – Code Walkthrough of a jQuery UI Widget
In the last post, Building Stateful jQuery UI Plugin Using Widget Factory, you were introduced to the working structure of jQuery UI Widgets. You learned that it uses the factory pattern is a way to generate different objects with a common interface. And that it Widget Factory adds features to jQuery plug-in. jQuery UI Widget... Continue Reading →
Object JavaScript – Building Stateful jQuery UI Plugin Using Widget Factory
In this post, you will learn step-by-step to build your own custom, reusable, testable jQuery UI widget. You will extend the jQuery library with custom UI code and then use it on a page. The initial plug-in will be trivial to demonstrate the jQuery Widget Factory pattern. You will provide properties that you can change... Continue Reading →
Object JavaScript – Building a Reusable Stateless jQuery Plugin
In this post, you will learn step-by-step to build your own custom, reusable, testable jQuery Plugin. There are times where you will want to reuse code that performs a series of operations on a selection. For example, you may want to embed information a span element and then have that information displayed in a references... Continue Reading →
Single Page App – isLoading jQuery Plugin to Indicate Content Loads
When you’re loading information using jQuery AJAX, you may want to provide visual feedback when loading data or for any action that would take time. In this Snippet, you will learn how to: Load JSON data from a getJSON call to our server. Show and hide a spinning indicator inside a div. Bind the incoming... Continue Reading →
Object JavaScript – External Templates Using Mustache, jQuery
As you have seen in Templates Rendering JSON Using Mustache, jQuery, you can put reusable HTML into a template and then have that template render your data. You are separating the data and providing one or more ways it can be displayed inside of a page. This post extends what you have learned about Mustache... Continue Reading →
Object JavaScript – Templates Rendering JSON Using Mustache, jQuery
In our previous posts, you see how you can create templates and load them asynchronously using Knockout. But not everyone needs Knockout’s functionality. Maybe you just want to get some data and display it using a template. Mustache is a library that allows you to read in JSON formatted data and display it using templates... Continue Reading →
Object JavaScript – Loading File Templates for Knockout Asynchronously Using koExternalTemplateEngine, Infuser
In the previous post, Using Infuser to Asynchronously Load Your Templates, we took a detour into Infuser and how it can be used to call template code. But what about calling Knockout templates? You will probably want to put a template into a separate file so you can reuse it across various pages on your... Continue Reading →
Object JavaScript – Using Infuser to Asynchronously Load Your Templates
In Introduction to Templates in MVVM Using Knockout.js, Mustache, you learned how you can use templates to a display and interact with Knockoutjs. But what if you would like to reuse those templates? Would you like to be able to load the templates asynchronously? And would you like to use the same techniques to load... Continue Reading →