add console.log(...)

This commit is contained in:
MihailRis
2024-06-07 23:14:16 +03:00
parent dd027e38fe
commit e8ea34fa31
2 changed files with 19 additions and 6 deletions
+1 -6
View File
@@ -38,12 +38,7 @@ function submit(text)
document.log.caret = -1
local status, result = pcall(function() return console.execute(text) end)
if result ~= nil then
local prevtext = document.log.text
if #prevtext == 0 then
document.log:paste(tostring(result))
else
document.log:paste('\n'..tostring(result))
end
console.log(result)
end
document.prompt.text = ""
document.prompt.focused = true