summaryrefslogtreecommitdiff
path: root/lambda-calcul/haskell/public/repl.js
diff options
context:
space:
mode:
Diffstat (limited to 'lambda-calcul/haskell/public/repl.js')
-rw-r--r--lambda-calcul/haskell/public/repl.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/lambda-calcul/haskell/public/repl.js b/lambda-calcul/haskell/public/repl.js
index 599d1f8..1d4453f 100644
--- a/lambda-calcul/haskell/public/repl.js
+++ b/lambda-calcul/haskell/public/repl.js
@@ -51,7 +51,9 @@ function appendOutput(text) {
function formatResult(text) {
const result = JSON.parse(text);
- if (result.tag === "Msg") {
+ if (result.rendered) {
+ return result.rendered;
+ } else if (result.tag === "Msg" ) {
return result.contents;
}
return text;