js/main.js
// Shows a skill on the DOM
Shows a skill on the DOM
Shows a skill on the DOM
function showSkill(skill) {
  let skillsList = $('#skillsList');
  let languagesList = $('#languages');
  let frameworksList = $('#frameworks');
  skillsList.append(
    '<div class="slide"><img src="' +
      skill.logo +
      '" title="' +
      skill.name +
      '"></div>'
  );
  if (skill.type) {
    let rating = calculateStars(skill.rating);
    let add;
    if (skill.type === 'language') {
      add = languagesList;
    } else if (skill.type === 'framework') {
      add = frameworksList;
    }
    add.append(
      '<li class="list-group-item wow fadeInDown"><div class="row"><div class="col-6">' +
        skill.name +
        closeDiv +
        '<div class="col-6 text-right">' +
        rating +
        '</div></div></li>'
    );
  }
}
function showSkill ( skill ) { let skillsList = $ ( '#skillsList' ) ; let languagesList = $ ( '#languages' ) ; let frameworksList = $ ( '#frameworks' ) ; skillsList . append ( '<div class="slide"><img src="' + skill . logo + '" title="' + skill . name + '"></div>' ) ; if ( skill . type ) { let rating = calculateStars ( skill . rating ) ; let add ; if ( skill . type === 'language' ) { add = languagesList ; } else if ( skill . type === 'framework' ) { add = frameworksList ; } add . append ( '<li class="list-group-item wow fadeInDown"><div class="row"><div class="col-6">' + skill . name + closeDiv + '<div class="col-6 text-right">' + rating + '</div></div></li>' ) ; } }
Shows a skill on the DOM
Shows a skill on the DOM