1.0.6 • Published 6 years ago

rubiks-cross-trainer v1.0.6

Weekly downloads
7
License
MIT
Repository
github
Last release
6 years ago

Travis build status Codecov branch npm downloads MIT License

gzip size size

Maintainability PRs Welcome

Getting started

npm install --save rubiks-cross-trainer

Why?

Forming the cross on your Rubik's Cube is the first step in CFOP. It should never take more than 8 moves to form your cross, and this library gives you a chance to practice at your own comfort.

API

import getRandomSolve from "rubiks-cross-trainer";

const scramble = getRandomSolve(1);
console.log(scramble);
// "F2 D' F2 U2 L' U' R2 F' R2 D' B' R2 U2 B U2 B' L2 D2 B U2 B"
// Returns a scramble that requires 1 move to form the cross

const anotherScramble = getRandomSolve(8);
console.log(anotherScramble);
// "B D2 U2 F' D2 F2 D2 R2 D2 B' F' D B L' D F R B U' R2"
// Returns a scramble that requires 8 moves to form the cross

const moreThanEightMoves = getRandomSolve(100);
console.log(moreThanEightMoves);
// undefined
// Returns undefined for ranges outside of 1-8

Inspiration

This JavaScript library was inspired by this Reddit thread.

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago