Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
KnockoutJS Web Development

You're reading from   KnockoutJS Web Development Efficiently work with data, web templates, and custom HTML tags using KnockoutJS

Arrow left icon
Product type Paperback
Published in Feb 2015
Publisher
ISBN-13 9781782161028
Length 178 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
John Farrar John Farrar
Author Profile Icon John Farrar
John Farrar
Arrow right icon
View More author details
Toc

The simpleGrid plugin

Just like jQuery allows for custom plugins, it is possible to use plugins with Knockout as well. Here, we are going to use a simple plugin to add grid functionality to our page. This plugin also smartly adds paging to the page. We will also do some simple CSS to set our grid so it loosens up the space between the cells in the table.

Tip

The reason we code with jQuery, KnockoutJS, Bootstrap, and other Don't Repeat Yourself (DRY) libraries is that they package our work. We don't have to rethink, recode, or repeat our work when this is done. Using solutions such as jQuery and KnockoutJS, we can DRY out our code by adding our own library extensions. The simple grid plugin is an example of this.

Note that we will cover enough detail in this book that by the end you should be able to modify this plugin or build your own. However, you will have to understand JavaScript, CSS, HTML, and other topics enough to get the job you are seeking to DRY out. Regarding KnockoutJS...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime