Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/simple_utility/src/json.deno.ts>jsonWrite

Useful snippet collection.
Go to Latest
function jsonWrite
import { jsonWrite } from "https://deno.land/x/simple_utility@v1.5.2/src/json.deno.ts";

Convert from object to JSON and write to file.

Examples

Example 1

await jsonWrite("./resource.json", {
    foo: "bar"
});

Parameters

path: string
data: T

Returns

Promise<void>