flashcardz
v1.0.4
Published
Intelligently quizzes you
Downloads
18
Readme
Flashcardz
Intelligently quizzes you
Features
- Small typos are (pretty intelligently) ignored
- You won't be quizzed too much over things you get right
- You'll be quizzed a lot over things you get wrong
- You won't see the same card over and over again (assuming you have enough cards); you'll get enough variety to learn
- Importing stacks of cards from Quizlet works
- Comes with a CLI that can help with basic things like removing duplicate cards or deleting your history of getting cards right/wrong
- Comes with an API so that you can get quizzed from any interface (not just a terminal emulator)
Install
Assuming you have Node, installing the CLI is as easy as:
npm install -g flashcardz
To use Flashcardz programatically, use
npm install --save flashcardz
Usage
CLI
Say you have a file called myfile
with flashcards (each card has a "front" and a "back" - normally, you see the front first and have to recall what the back is). Let's say myfile
looks like this:
ostensible stated or appearing to be true, but not necessarily so.
palpable able to be touched or felt.
diaphanous (especially of fabric) light, delicate, and translucent.
ProTip™: if you're studying stuff on Quizlet, you can just export your set of cards with the default settings to get a file like myfile
in this example
Converting that file to a Flashcardz stack would look like this:
flash convert myfile tab/newline > mystack
The command above will convert myfile
to a "stack" which would be saved as mystack
which you can be quized on if you run:
flash quiz mystack
The CLI has many other commands. If you run flash help
you can see a list of them and the arguments they take. You can also get help for individual commands with flash help [command]
, e.g. flash help convert
JS API
const f = require('flashcardz')
// Convert this nice-looking object with flashcards into the Flashcardz format
const myCards = f.convert({
ostensible: 'stated or appearing to be true, but not necessarily so.',
palpable: 'able to be touched or felt.',
diaphanous: '(especially of fabric) light, delicate, and translucent.'
}, 'objecty')
// Get quized on the terminal over 1 card in that stack of flashcards
const myCardsAfterQuiz = flashcardz.quiz(myCards, require('flashcardz/cli-quizzer'), flashcardz.pick.random)
// Get the term that you struggled with most from quizzes
const hardestCard = flashcardz.hardest(myCardsAfterQuiz)
console.log(hardestCard.front + ' is a difficult word.') // ex: 'ostensible is a difficult word.'
Documentation
Documentation for the JS API is here, in js-api.md
Documentation for the CLI is here, in cli.md
Contributing
Contributions welcome! Please read the contributing guidelines first.
License
This is licensed under the ISC License