Skip to main content
Deno 2 is finally here πŸŽ‰οΈ
Learn more
Module

x/redis/mod.ts>createLazyClient

πŸ¦• Redis client for Deno πŸ•
Very Popular
Go to Latest
function createLazyClient
import { createLazyClient } from "https://deno.land/x/redis@v0.27.0/mod.ts";

Create a lazy Redis client that will not establish a connection until a command is actually executed.

import { createLazyClient } from "./mod.ts";

const client = createLazyClient({ hostname: "127.0.0.1", port: 6379 });
console.assert(!client.isConnected);
await client.get("foo");
console.assert(client.isConnected);