//- 💫 INCLUDES > FUNCTIONS //- More descriptive variables for current.path and current.source - CURRENT = current.source - SECTION = current.path[0] - SUBSECTION = current.path[1] //- Add prefixes to items of an array (for modifier CSS classes) - function prefixArgs(array, prefix) { - return array.map(function(arg) { - return prefix + '--' + arg; - }).join(' '); - } //- Generate GitHub links - function gh(repo, filepath, branch) { - var branch = ALPHA ? 'develop' : branch - return 'https://github.com/' + SOCIAL.github + '/' + repo + (filepath ? '/blob/' + (branch || 'master') + '/' + filepath : '' ); - } //- Get social images - function getSocialImg() { - var base = SITE_URL + '/assets/img/social/preview_' - var image = 'default' - if (preview) image = preview - else if (SECTION == 'docs') image = 'docs' - return base + image + '.jpg' - }