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

x/gustwind/server-deps.ts>fs.format

πŸ³πŸ’¨ – Deno powered site creator
Go to Latest
function fs.format
import { fs } from "https://deno.land/x/gustwind@v0.59.1/server-deps.ts";
const { format } = fs;

Format the file to the targeted EOL.

Examples

Example 1

import { EOL, format } from "https://deno.land/std@0.224.0/fs/mod.ts";

const CRLFinput = "deno\r\nis not\r\nnode";

format(CRLFinput, EOL.LF); // output "deno\nis not\nnode"

Parameters

content: string
eol: EOL

Returns

string