aboutsummaryrefslogtreecommitdiff
path: root/src/lib/info.ts
diff options
context:
space:
mode:
authorBobby <[email protected]>2022-01-26 14:02:00 -0500
committerBobby <[email protected]>2022-01-26 14:02:00 -0500
commitdca40908a25b155dfed169f0260ec3083df90ed1 (patch)
tree58881f81ab9fff311a7618a158ae6e85bd13f609 /src/lib/info.ts
parent901901f0cc4795305d368f588a2d18fe2a8e28b2 (diff)
downloadizuku.js-dca40908a25b155dfed169f0260ec3083df90ed1.tar.xz
izuku.js-dca40908a25b155dfed169f0260ec3083df90ed1.zip
chore: remove table dependency and replace it with internal function
Diffstat (limited to 'src/lib/info.ts')
-rw-r--r--src/lib/info.ts6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/lib/info.ts b/src/lib/info.ts
index 3753782..98a6249 100644
--- a/src/lib/info.ts
+++ b/src/lib/info.ts
@@ -1,7 +1,7 @@
import { Frame } from '../index';
-import { table } from 'table';
import { sizeof } from '../helpers/memorySize';
import { flatten } from './data';
+import { displayTable } from './display';
/**
* size returns the total number of elements in the frame
* @returns the total number of elements in the frame
@@ -74,9 +74,7 @@ export function info(this: Frame): void {
.split(' x ')[1]
.trim()} columns`
);
- console.log(table(info));
- // Remove the previous printed newline
- process.stdout.write('\x1B[1A\x1B[2K');
+ displayTable(info);
console.log(`Data Types: ${dataTypesString}`);
console.log(`Memory Usage: ${sizeof(this)} bytes`);
}