Overview
Introduction
Editing a single item deep inside a long pasted list by hand means carefully counting lines and not fat-fingering a neighboring item.
This tool does one precise edit for you: insert a new value, delete an item, or replace an item, at whatever position you specify.
What Is List Editor?
A single-operation list editor that applies an insert, delete, or replace at a 1-based index you choose, then prints the resulting list.
It supports the same configurable separator (newline, comma, or a custom delimiter) as every other tool in the List category, so it works on however your list is formatted.
How List Editor Works
The input is split into items on the resolved separator, then the chosen operation is applied at the given index using the same semantics as JavaScript's Array.prototype.splice.
Insert places the new value immediately before the given index (so index length+1 appends at the end); delete and replace both require an index within the existing list's bounds.
When To Use List Editor
Use it when you need to fix, add, or remove exactly one entry in a list without retyping the whole thing.
It's handy for quick config-list or CSV-column edits where opening a full spreadsheet or editor feels like overkill.
Often used alongside List Splicer, List Item Shifter and Sublist Extractor.
Features
Advantages
- 1-based indexing matches how people naturally count list items, no off-by-one mental math required.
- Clear, specific error messages when an index is out of range, instead of a silently wrong output.
- Works with any separator, not just newlines, so comma- or pipe-delimited lists are just as easy to edit.
Limitations
- Only one edit per run; use List Splicer if you need to remove a run of items and insert several replacements at once.
- Insert and replace both require a non-empty value; there is no way to insert an empty item with this tool.
Examples
Best Practices & Notes
Best Practices
- Count from the top of your list when picking an index; the tool always uses 1-based positions regardless of separator.
- Use List Splicer instead if you need to remove several consecutive items and insert several new ones in one operation.
Developer Notes
Internally the operation is implemented with a single Array.prototype.splice call after converting the 1-based index to a 0-based one, mirroring the same index math JavaScript's splice uses.
List Editor Use Cases
- Fixing a typo'd entry in a pasted list without retyping the whole thing
- Inserting a new row into a short CSV-like column of values
- Removing a single stale entry from a config or allow-list
Common Mistakes
- Forgetting insert uses length+1 to append, and instead trying to use an index equal to the current length.
- Passing an empty value to insert or replace, which is rejected since an empty item is rarely intentional.
- Assuming the index is 0-based, like an array index, when it's actually 1-based.
Tips
- Preview the item count in your input before picking an index, especially with a custom separator.
- Chain this with List Splitter if you want to see the list broken into two parts before deciding where to edit.