Created
November 2, 2025 14:58
-
-
Save veracioux/167b3645c23ccb29620814789ea1565f to your computer and use it in GitHub Desktop.
OpenTUI character delete crash
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { TextareaRenderable } from "@opentui/core" | |
| import { createEffect } from "solid-js" | |
| export function App() { | |
| let input: TextareaRenderable | |
| createEffect(() => { | |
| input.insertText("a ".repeat(200)) | |
| }) | |
| return ( | |
| <box style={{ border: true, padding: 2, flexDirection: "column", gap: 1 }}> | |
| <text fg="#FFFF00">Hello, OpenTUI with Solid!</text> | |
| <text>This is a sample project.</text> | |
| <box style={{ border: true, width: 40, height: 3 }}> | |
| <textarea | |
| ref={(r: TextareaRenderable) => (input = r)} | |
| focused | |
| /> | |
| </box> | |
| </box> | |
| ) | |
| } | |
| export const app = () => <App /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { render } from "@opentui/solid" | |
| import { app } from "./app" | |
| render(app, { | |
| exitOnCtrlC: true, | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "name": "opentui", | |
| "private": true, | |
| "scripts": { | |
| "start": "bun src/index.ts" | |
| }, | |
| "devDependencies": { | |
| "@types/bun": "latest" | |
| }, | |
| "peerDependencies": { | |
| "typescript": "^5" | |
| }, | |
| "dependencies": { | |
| "@opentui/core": "^0.1.32", | |
| "@opentui/solid": "^0.1.32", | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment