I have a helper function that turns minutes into hours/mins. I currently have it in my layout.cshtml but each page cannot see the function. Where should I put the helper function such that every page can see it?
@helper DisplayElapsedTime(int timeInMins){
String timeStr = "";
if (timeInMins >= 60) {
int hours = timeInMins/60;
timeInMins -= hours * 60;
timeStr = hours + "h ";
}
if (timeInMins > 0){
timeStr += timeInMins + "m";
}
@timeStr;
}