Skip to content

Latest commit

 

History

History
30 lines (21 loc) · 693 Bytes

README.md

File metadata and controls

30 lines (21 loc) · 693 Bytes

Dublet

A mini link shortener built with the Dub.co TypeScript SDK.

import { Dub } from "dub";

const dub = new Dub({
  token: process.env.DUB_API_KEY, // optional: defaults to the `DUB_API_KEY` environment variable
});

async function shorten() {
  const result = await dub.links.create({
    url: "https://google/com",
  });

  // Handle the result
  console.log(result);
}

Demo

CleanShot.2024-01-18.at.15.58.33.mp4

Stack

  • Link Management Infrastructure: Dub.co
  • Framework: Next.js + Server Actions
  • UI: v0