Tip
I can’t remember ever building an app that didn’t have a table at one point or another. Here is an addon to make creating a table a breeze.
Install the addon
1 |
ember install ember-models-table |
Add the component to your template
1 |
{{models-table data=model columns=columns}} |
Configure your columns:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
columns: [ { "propertyName": "id", "title": "ID" }, { "propertyName": "firstName", "title": "First Name" }, { "propertyName": "lastName", "title": "Last Name" }, { "propertyName": "city", "title": "City" } ] |
And you get this:
There are many options and configurations. Check the documentation for more details.
Credits & Links
ember-models-table repo at https://github.com/onechiporenko/ember-models-table
documentation at http://onechiporenko.github.io/ember-models-table/
demos at http://onechiporenko.github.io/ember-models-table/examples
My Latest Side Project
Hire JS – Top Javascript Developers
Hire JS is a community of top Javascript developers and top javascript jobs. We have top quality javascript, web, mobile, angular, react, ember and node developers. We have remote jobs, full and part time jobs, contracts. Save yourself time, effort and money and find the perfect developer and project.
Share A Tip
Email me at emad@emberdaily.tips if you have a good ember tip.
If you are enjoying my daily tips please spread the word with this one-click tweet.
If you do NOT like the tips then please reply to this email and let me know how I can improve them.