view src/tools/request.txt.luan @ 51:78b2d6995244

add preview
author Franklin Schmidt <fschmidt@gmail.com>
date Tue, 22 Nov 2022 22:57:43 -0700
parents 2f20b11affdd
children
line wrap: on
line source

local Binary = require "luan:Binary.luan"
local Io = require "luan:Io.luan"
local Http = require "luan:http/Http.luan"


return function()
	Io.stdout = Http.response.text_writer()
	%><%= Http.request.raw_head %><%
	if Http.request.body ~= nil then
		%><%=Binary.to_string(Http.request.body,"utf-8")%><%
	end
end