square

v1.0.0arrow_drop_down
v1.0.0
v0.1.5
v0.1.4
v0.1.3
v0.1.2
v0.1.1
v0.1.0
v0.0.1
STATUS
Passing
DOWNLOADS
215
LICENSE
MIT
VISIBILITY
Public
PUBLISHED
5 years ago
SIZE
3 KB
Square is a cell in the main 2d array, and can receive any value and optional color.
1 contributor
Install square as a package?
Copied
npm i @bit/joshk.tic-tac-toe-game.square
Set Bit as a scoped registryLearn more
npm config set '@bit:registry' https://node.bit.cloud
Component Example
React
React
Vue
Angular
React Native
Add dependency... help_outline
Just
import
any of the 1 million components
and packages in Bit or NPM to the example.
import Button from '@bit/grommet.grommet.button';
import Lodash from 'lodash';
toggle layout
modifieddraft
chevron_left
chevron_right
Square ()

Square is a cell in the main 2d array, and can receive any value and optional color.

Example
import React from 'react';
import Square from '@bit/joshk.tic-tac-toe-game.square';

export default (
<Square value="O"/>
)
Properties
NameTypeDescription
row
(required)
number

row value in 2d array to be returned when is clicked

col
(required)
number

column value in 2d array to be returned when is clicked

setValue
(required)
Function

function that called to send row and column values to update value in 2d array

value
(required)
string

value to set (X/O)

disable
(required)
boolean

disable the square

color
string

optional hex color to override X and O color

Help and resources