MCPcopy
hub / github.com/github/awesome-copilot / getLastUpdatedHtml

Function getLastUpdatedHtml

website/src/scripts/utils.ts:752–763  ·  view source on GitHub ↗
(isoDate: string | null | undefined)

Source from the content-addressed store, hash-verified

750 * @returns HTML string with relative time and title attribute
751 */
752export function getLastUpdatedHtml(isoDate: string | null | undefined): string {
753 const relativeTime = formatRelativeTime(isoDate);
754 const fullDate = formatFullDate(isoDate);
755
756 if (relativeTime === "Unknown") {
757 return `<span class="last-updated">Updated: Unknown</span>`;
758 }
759
760 return `<span class="last-updated" title="${escapeHtml(
761 fullDate
762 )}">Updated ${relativeTime}</span>`;
763}

Callers 6

renderInstructionsHtmlFunction · 0.90
renderAgentsHtmlFunction · 0.90
renderHooksHtmlFunction · 0.90
renderSkillsHtmlFunction · 0.90
renderExtensionsHtmlFunction · 0.90
renderWorkflowsHtmlFunction · 0.90

Calls 3

formatRelativeTimeFunction · 0.85
formatFullDateFunction · 0.85
escapeHtmlFunction · 0.70

Tested by

no test coverage detected