소스 검색

Fix name of OutputLogger class in example

ApisNecros 1 년 전
부모
커밋
277d145133
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      README.md

+ 2 - 2
README.md

@@ -72,7 +72,7 @@ The `CodeBox` class constructor's third parameter is an optional object of optio
 In the following example, we create an `OutputLogger` object that stores the output from the Code Box. Then, after the Code Box has run, we can output all of the values as one whole string. If we were to just use the initial value of `console.log` as the output function, we would get each character on a new line.
 
 ```Javascript
-class OutputJoiner {
+class OutputLogger {
    constructor(joinChar = "") {
       this.out = "";
       this.JOIN_CHAR = joinChar;
@@ -88,7 +88,7 @@ class OutputJoiner {
    }
 }
 
-const output = new OutputJoiner();
+const output = new OutputLogger();
 const cb = new CodeBox(`"Hello, World!"r>Ool?u!|;`, [], {
    outputCallback: output.push.bind(output),
 });