Skip to content

Instantly share code, notes, and snippets.

@calvinnr7
Created June 27, 2016 03:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save calvinnr7/bc0ce1cc477bd1312427d5445e999843 to your computer and use it in GitHub Desktop.
Save calvinnr7/bc0ce1cc477bd1312427d5445e999843 to your computer and use it in GitHub Desktop.
({
doInit: function(component, event, helper) {
//Fetch the asteroid list from the Apex controller
helper.getAsteroidList(component);
},
showDetails: function(component, event, helper) {
//Get data via "data-data" attribute from button (button itself or icon's parentNode)
var url = event.target.getAttribute("data-data") || event.target.parentNode.getAttribute("data-data")
},
searchAsteroids: function(component, event, helper) {
helper.getAsteroidList(component);
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment