[PR #17] [MERGED] Add insert before function #221

Closed
opened 2026-03-02 23:45:29 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/anomalyco/opentui/pull/17
Author: @fezproof
Created: 8/15/2025
Status: Merged
Merged: 8/15/2025
Merged by: @kommander

Base: mainHead: insert-before


📝 Commits (1)

  • 9b59ab6 Add insert before function

📊 Changes

1 file changed (+32 additions, -3 deletions)

View changed files

📝 src/Renderable.ts (+32 -3)

📄 Description

Remove some duplicate logic to replace parents
Add insert before, follow web convention

You can now call

parent.insertBefore(childObj, anchorObj);

// OR

parent.insertBefore(childObj); // this will act just like parent.add(childObj)

Closes #16


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/anomalyco/opentui/pull/17 **Author:** [@fezproof](https://github.com/fezproof) **Created:** 8/15/2025 **Status:** ✅ Merged **Merged:** 8/15/2025 **Merged by:** [@kommander](https://github.com/kommander) **Base:** `main` ← **Head:** `insert-before` --- ### 📝 Commits (1) - [`9b59ab6`](https://github.com/anomalyco/opentui/commit/9b59ab6239d61bb5362a37846b83f372088bfed8) Add insert before function ### 📊 Changes **1 file changed** (+32 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `src/Renderable.ts` (+32 -3) </details> ### 📄 Description Remove some duplicate logic to replace parents Add insert before, follow web convention You can now call ```typescript parent.insertBefore(childObj, anchorObj); // OR parent.insertBefore(childObj); // this will act just like parent.add(childObj) ``` Closes #16 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-02 23:45:29 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/opentui#221
No description provided.