js-brainfuck is a simple Node module for interpreting js-brainfuckBrainFuck
Example use:
const { brainfuck } = require("js-brainfuck");
const brainfuckCode = "++++++++[>++++++++<-]>."; // prints ASCII 64: @
const brainfuckOptions = {
input: "", // Input. The , operator reads a single character from this every time it's called
invalidCommandError: true // Whether or not to throw an error when an invalid command/operator is reached. (Default: false)
};
brainfuck(brainfuckCode, brainfuckOptions).then(output => {
console.log(output); // Logs the output. In this case, the output will be "@"
});
Running brainfuck() will return a
Promise<string>