Added fbjs eslint config, fixed lint errors and warnings

This commit is contained in:
jxom
2017-10-10 08:41:44 +11:00
parent 5a96b1da03
commit de3bd87f4b
7 changed files with 20 additions and 9 deletions

View File

@@ -26,10 +26,9 @@ const isItemActive = (location, item) => {
}
} else if (item.id.includes('html')) {
return location.pathname.includes(item.id);
} else {
const slugId = location.pathname.split('/').slice(-1)[0];
return slugId === slugify(item.id);
}
const slugId = location.pathname.split('/').slice(-1)[0];
return slugId === slugify(item.id);
};
export default isItemActive;