Skip to main content
Glama
date.js462 B
import { truncate } from './helpers' export default function inspectDate(dateObject, options) { const stringRepresentation = dateObject.toJSON() if (stringRepresentation === null) { return 'Invalid Date' } const split = stringRepresentation.split('T') const date = split[0] // If we need to - truncate the time portion, but never the date return options.stylize(`${date}T${truncate(split[1], options.truncate - date.length - 1)}`, 'date') }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/yogendhra9/ZerodhaMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server