my-io-sync

This package provides sync IO method for nodejs

Usage no npm install needed!

<script type="module">
  import myIoSync from 'https://cdn.skypack.dev/my-io-sync';
</script>

README

IOSync

npm version Build Status
This package provides sync IO method for nodejs.

Install

npm install my-io-sync --save-dev

Usage

Import

let {print, println, raw_input, input} = require("my-io-sync");

Output

  • print(...texts) Print texts
  • println(...texts) Print texts and line feed
let {print, println} = require("my-io-sync");
println("Hello world!");
print("Hello world!");

Input

  • raw_input(...texts) Print texts and input(return String value)
  • input(text, transType = "String") Print text and input(return (transType) value)
let {println, raw_input, input} = require("my-io-sync");
let name = raw_input("Name:");
let age = input("Age:", "Number");
println(name, age);

License

MIT license