39 lines
932 B
JavaScript
39 lines
932 B
JavaScript
/*
|
|
* Copyright (C) Sapphirecode - All Rights Reserved
|
|
* This file is part of console-app which is released under MIT.
|
|
* See file 'LICENSE' for full license details.
|
|
* Created by Timo Hocker <timo@scode.ovh>, May 2020
|
|
*/
|
|
|
|
// @ts-nocheck
|
|
/* eslint-disable no-console */
|
|
/* eslint-disable id-match */
|
|
/* eslint-disable node/no-missing-require */
|
|
|
|
'use strict';
|
|
|
|
const {
|
|
StringOption,
|
|
BooleanOption,
|
|
NumberOption,
|
|
ArrayOption,
|
|
FolderOption
|
|
} = require ('./dist/lib/index.js');
|
|
|
|
(async () => {
|
|
const str = await new StringOption ({ name: 'str' })
|
|
.parse ();
|
|
const bool = await new BooleanOption ({ name: 'bool' })
|
|
.parse ();
|
|
const num = await new NumberOption ({ name: 'num' })
|
|
.parse ();
|
|
const arr = await new ArrayOption ({ name: 'arr' })
|
|
.parse ();
|
|
const fld = await new FolderOption ({ name: 'fld' })
|
|
.parse ();
|
|
|
|
const data = { str, bool, num, arr, fld };
|
|
|
|
console.log (data);
|
|
}) ();
|