mirror of
https://github.com/hazemKrimi/touch-programming.git
synced 2026-05-01 18:20:26 +00:00
Testing languages
This commit is contained in:
+1
-1
@@ -11,7 +11,7 @@ function App() {
|
||||
|
||||
useEffect(() => {
|
||||
(async function() {
|
||||
const response = await fetch(`${import.meta.env.VITE_API_URL}/generate?lang=typescript&lines=20`);
|
||||
const response = await fetch(`${import.meta.env.VITE_API_URL}/generate?lang=scala&lines=20`);
|
||||
const reader = response.body.getReader();
|
||||
const decoder = new TextDecoder();
|
||||
|
||||
|
||||
@@ -108,7 +108,6 @@ func main() {
|
||||
cleaned := parser.ParseStream(chunk)
|
||||
|
||||
if len(cleaned) > 0 {
|
||||
fmt.Println(chunk, string(chunk))
|
||||
ctx.Response().Write(cleaned)
|
||||
ctx.Response().Flush()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user