Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/lucid/src/provider/mod.ts>datumJsonToCbor

Lucid is a library, which allows you to create Cardano transactions and off-chain code for your Plutus contracts in JavaScript, Deno and Node.js.
Go to Latest
variable datumJsonToCbor
import { datumJsonToCbor } from "https://deno.land/x/lucid@0.5.2/src/provider/mod.ts";

This function is temporarily needed only, until Blockfrost returns the datum natively in cbor

The conversion is ambigious, that's why it's better to get the datum directly in cbor

type

(json: DatumJson) => Datum