tiny-essentials
Version:
Collection of small, essential scripts designed to be used across various projects. These simple utilities are crafted for speed, ease of use, and versatility.
11 lines • 728 B
text/typescript
/**
* Handles the cookie session for a socket connection by simulating an Express request and response.
* This function uses the provided session module to manage session data for the socket connection.
*
* @param {Record<string, any>} socket - The socket object representing the connection.
* @param {Function} sessionModule - The session module function, typically used with Express, that handles session logic.
* @returns {Promise<Record<string, any>>} A promise that resolves with the session object once the session is processed.
* @deprecated
*/
export default function cookieSession(socket: Record<string, any>, sessionModule: Function): Promise<Record<string, any>>;
//# sourceMappingURL=cookie-session.d.mts.map