waltz-ng/client/cost/components/app-costs-summary-section/app-costs-summary-section.js
/**
 * Determines the default cost kind by either finding a
 * cost kind flagged as the default or falling back to the
 * first cost kind if none are flagged.
 *
 * @param costKinds
 * @returns {unknown}
 */
Determines the default cost kind by either finding a
cost kind flagged as the default or falling back to the
first cost kind if none are flagged.

@param costKinds
@returns {unknown}
Determines the default cost kind by either finding a cost kind flagged as the default or falling back to the first cost kind if none are flagged . @param costKinds @returns { unknown }
function findDefaultKind(costKinds = []) {
    const defaultKind = _.find(costKinds, d => d.isDefault);
    return defaultKind
        ? defaultKind
        : _.first(costKinds);
}
function findDefaultKind ( costKinds = [ ] ) { const defaultKind = _ . find ( costKinds , d => d . isDefault ) ; return defaultKind ? defaultKind : _ . first ( costKinds ) ; }
Determines the default cost kind by either finding a
 cost kind flagged as the default or falling back to the
 first cost kind if none are flagged.
Determines the default cost kind by either finding a cost kind flagged as the default or falling back to the first cost kind if none are flagged .