You need to sign in to do that
Don't have an account?
Big Ears
Lightning Components - Some Javascript questions
All,
I've been working through the "Lightning Components Basics" Trailhead module and found it to be, in the main, really helpful. However, there are a few points in the examples where methods/techniques are used which aren't clarified and I can't find in the documentation either. I'm trying to work out if these are specific to the Lightning implementation of Javascript, standard Javascript methods or something else that I should read for additional understanding:
Thanks!
I've been working through the "Lightning Components Basics" Trailhead module and found it to be, in the main, really helpful. However, there are a few points in the examples where methods/techniques are used which aren't clarified and I can't find in the documentation either. I'm trying to work out if these are specific to the Lightning implementation of Javascript, standard Javascript methods or something else that I should read for additional understanding:
- When setting up asyncronous callback responses, there are 2 methods that I can't find in the Lightning documentation or with a Google search, so what are they native to?
- getReturnValue()
- getState()
- When setting up a variable to run an apex method, there are methods which I have a similar issue with:
- setParams()
- In another module, 2 methods in the Helper class for a component call another method within the same Helper class with the "this." nomenclature. Given that these methods are all held in a map, is this a standard Javascript technique or something else?
Thanks!
You can also get details in the JavaScript API > Action node of the reference doc app. See https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/ref_doc_app.htm
Use this.helperMethod2() to call a second helper method from within a helper. This is the way to do it with Lightning components. I'll update the doc to make this clearer.
Thanks for the feedback!