@cursorsdottsx/l
v1.1.0
Published
Loop easily without overhead, and dumb chad for loops.
Downloads
3
Readme
| a | b | c | d | e | f | g | h | i | j | k | l | m | n | o | p | q | r | s | t | u | v | w | x | y | z |
L is for Loop
@cursorsdottsx/l
Loop easily without overhead, and dumb chad for loops.
require("@cursorsdottsx/l");
(42).times((i) => {
console.log(`Hello ${i}!`);
});
To use the continue
keyword, we have return
.
To use break
, we have throw new Error()
, which is better in that it requires you to type an extra try-catch around the loop.
To use break <block>;
or continue <block>;
, fuck you.
Install with either NPM or Yarn:
require("@cursorsdottsx/l");
import "@cursorsdottsx/l";
Documentation thats not needed
Number.prototype.times
– Almost the same as Ruby's times
method.