Skip to content

rscouto/gridView

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

#GridView

Generates table markup with JSON input. It also supports mapping JSON properties to custom table headers.

Example

Markup

<div id="myTable"></div>

Javascript

var people = [
	{
		firstName: 'Breno',
		lastName: 'Ferreira',
		email: 'breno@example.com',
		age: 23
	},
	{
		firstName: 'Rodrigo',
		lastName: 'Vidal',
		email: 'vidal@example.com',
		age: 23
	},
	{
		firstName: 'Rodrigo',
		lastName: 'Andrade',
		email: 'andrade@example.com',
		age: 23
	}
];

var mapping = {
	firstName: 'First Name',
	lastName: 'Last Name',
	email: 'Email',
	age: 'Age'
};

$('#myTable').gridView({data:people,headerMappings:mapping});

For a more comprehensive sample, check samples in sample folder

About

Generates <table> markup with JSON input.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%