I'm working on a custom navigation webpart for SP2013 using the JSOM.
Currently, a part of fetching the data from the termstore involves fetching all the terms and then getting data from the respective taxonomy terms:
context.load(term, ['Title', 'FriendlyUrlSegment', 'Terms', 'Parent']); taxonomyTerm = term.getTaxonomyTerm(); context.load(taxonomyTerm);
Later on in the code I can access the data from the taxonomy term via
This brings me to two questions:
- Is this the right way to ask for the properties I want from the taxonomy term?
- How can I optimize the above request by specifying the fields I'm after for the taxonomy term, how can I see what options I have?