solid-square

1.0.0 • Public • Published

solid-square Build Status codecov

Render solid squares of varying sizes and colors

Install

$ npm install solid-square

Usage

const solidSquare = require('solid-square');
 
console.log(solidSquare(10));
// ████████████████████
// ████████████████████
// ████████████████████
// ████████████████████
// ████████████████████
// ████████████████████
// ████████████████████
// ████████████████████
// ████████████████████
// ████████████████████
const solidSquare = require('solid-square');
 
console.log(
  solidSquare(10, {
    character: '',
    color: 'yellow',
    scale: .5
  });
);
// ☺☺☺☺☺☺☺☺☺☺
// ☺☺☺☺☺☺☺☺☺☺
// ☺☺☺☺☺☺☺☺☺☺
// ☺☺☺☺☺☺☺☺☺☺
// ☺☺☺☺☺☺☺☺☺☺

API

solidSquare(size, [options])

size

Type: number

The size of your square.

options

Type: Object

character

Type: string
Default: ██

The character to use for each cell.

color

Type: string
Default: undefined

The character to use for each cell.

scale

Type: string
Default: undefined

Y-axis size multiplier.

License

MIT © Chris Vogt

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.0
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.0
    1

Package Sidebar

Install

npm i solid-square

Weekly Downloads

1

Version

1.0.0

License

MIT

Unpacked Size

4.54 kB

Total Files

4

Last publish

Collaborators

  • chrisvogt