summaryrefslogtreecommitdiff
path: root/std/encoding/_yaml/example
diff options
context:
space:
mode:
authorNayeem Rahman <nayeemrmn99@gmail.com>2020-06-12 20:23:38 +0100
committerGitHub <noreply@github.com>2020-06-12 15:23:38 -0400
commit1fff6f55c3ba98a10018c6d374795e612061e9b6 (patch)
tree12074b6d44736b11513d857e437f9e30a6bf65a4 /std/encoding/_yaml/example
parent26bf56afdaf16634ffbaa23684faf3a44cc10f62 (diff)
refactor: Don't destructure the Deno namespace (#6268)
Diffstat (limited to 'std/encoding/_yaml/example')
-rw-r--r--std/encoding/_yaml/example/sample_document.ts4
1 files changed, 1 insertions, 3 deletions
diff --git a/std/encoding/_yaml/example/sample_document.ts b/std/encoding/_yaml/example/sample_document.ts
index da969d679..f66b3c417 100644
--- a/std/encoding/_yaml/example/sample_document.ts
+++ b/std/encoding/_yaml/example/sample_document.ts
@@ -3,10 +3,8 @@
import { parse } from "../../yaml.ts";
-const { readFileSync, cwd } = Deno;
-
(() => {
- const yml = readFileSync(`${cwd()}/example/sample_document.yml`);
+ const yml = Deno.readFileSync(`${Deno.cwd()}/example/sample_document.yml`);
const document = new TextDecoder().decode(yml);
const obj = parse(document) as object;