This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
paparanKu = Backbone.View.extend({ | |
events: { | |
"click #elemenKu": "caraKu" | |
}, | |
caraKu: function(){ | |
alert("Tidak Menyesal Belajar BackboneJS!"); | |
}, | |
render: function(){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Collecting all unique affected app version for a given data set | |
var jsonStats = [ | |
{app_versions: ['1.2','1.2.3']}, | |
{app_versions: null}, | |
{app_versions: ['1.2','1.3']} | |
]; | |
var app_versions = _.uniq(_.flatten(_.compact(_.map(jsonStats, function(day){return day.app_versions })))); | |
// ["1.2", "1.2.3", "1.3"] | |
// Bye bye stupid for loops! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var data = { | |
type: "something", | |
name: "whatever", | |
addresses: [ | |
{ | |
type: "read_address", | |
address: "1/2/3", | |
value: "10" | |
}, | |
{ |
NewerOlder