Printf
printf
Full implementation of the printf
/sprintf
family in pure JS.
_ _ __
(_) | | / _|
_ __ _ __ _ _ __ | |_| |_
| '_ \| '__| | '_ \| __| _|
| |_) | | | | | | | |_| |
| .__/|_| |_|_| |_|\__|_|
| |
|_|
Get it: npm install printf
Sample usage:
1 2 3 |
|
Flags:
(space)
+
-
0
Features:
Width / precision
=>%2f
Numerical bases
=>%c
Miscellaneous
=>%d%%
,+%s%+
Extra
=> The%O
converter will callutil.inspect(...)
at the argument,%-*.*f
.
GIF FTW!
Thanks to Worms David for printf
!
printf('******************%s**************',"Merry Xmas!")