[{"data":1,"prerenderedAt":118},["ShallowReactive",2],{"guide-how-to-clean-a-list-of-text":3},{"id":4,"title":5,"author":6,"body":7,"category":105,"categorySlug":106,"date":107,"description":108,"extension":109,"image":110,"meta":111,"navigation":112,"path":113,"seo":114,"slug":115,"stem":116,"__hash__":117},"articles\u002Farticles\u002Fhow-to-clean-a-list-of-text.md","How to clean and organize a pasted list of text","btools",{"type":8,"value":9,"toc":99},"minimark",[10,20,25,28,39,59,70,74,85,92,96],[11,12,13,14,19],"p",{},"Copied lists often contain blank rows, extra spaces and repeated entries. The\n",[15,16,18],"a",{"href":17},"\u002Ftext-processor","text processor"," can clean these in a sequence. It works in your browser, so the\ntext you paste is not uploaded to btools.",[21,22,24],"h2",{"id":23},"a-concrete-example","A concrete example",[11,26,27],{},"Suppose you paste this list, where the second line has spaces before the name:",[29,30,36],"pre",{"className":31,"code":33,"language":34,"meta":35},[32],"language-text","Apple\n  Pear\n\nApple\nBanana\n","text","",[37,38,33],"code",{"__ignoreMap":35},[11,40,41,42,46,47,50,51,54,55,58],{},"First choose ",[43,44,45],"strong",{},"Trim lines"," to remove spaces at the start and end of each line. Then choose\n",[43,48,49],{},"Remove empty lines",", followed by ",[43,52,53],{},"Remove duplicate lines",". The result contains Apple, Pear and\nBanana once each. Choose ",[43,56,57],{},"Sort ascending"," if you want alphabetical order.",[11,60,61,62,65,66,69],{},"The order matters. Deduplication compares whole lines exactly, so ",[37,63,64],{},"Pear"," and ",[37,67,68],{}," Pear "," count as\ndifferent until you trim them. Sorting first can make duplicates easier to spot, but it changes the\noriginal order. If order matters, leave sorting until the end or skip it.",[21,71,73],{"id":72},"make-a-list-ready-for-another-app","Make a list ready for another app",[11,75,76,77,80,81,84],{},"Use ",[43,78,79],{},"Add prefix \u002F suffix to each line"," to turn each entry into a bullet, numbered label or a\nsimple quoted value. ",[43,82,83],{},"Find and replace"," changes every occurrence of the text you specify. Check\nthe result before copying it, especially if your search text also appears inside longer words.",[11,86,87,88,91],{},"For structured data, ",[43,89,90],{},"Format JSON"," accepts valid JSON and indents it for reading. It reports an\nerror for invalid JSON rather than silently changing the data. Formatting does not validate that\nyour JSON fields have the meaning another application expects.",[21,93,95],{"id":94},"keep-the-source-while-experimenting","Keep the source while experimenting",[11,97,98],{},"Operations use the current result, so you can combine them. The input remains available while you\nwork; edit it to begin a new sequence. Copy the final result only after checking line order,\nduplicates and punctuation.",{"title":35,"searchDepth":100,"depth":100,"links":101},2,[102,103,104],{"id":23,"depth":100,"text":24},{"id":72,"depth":100,"text":73},{"id":94,"depth":100,"text":95},"Text processing","text-processing","2026-10-08","Remove blank lines, trim whitespace, deduplicate and sort a list in the browser without uploading its contents.","md",null,{},true,"\u002Farticles\u002Fhow-to-clean-a-list-of-text",{"title":5,"description":108},"how-to-clean-a-list-of-text","articles\u002Fhow-to-clean-a-list-of-text","V0k2cIL21t9rVd6IwXi62q0QGH6v-0tZbUOrWZSeop4",1791431549814]