Gist e1cf65595f69eb8a0e59eeecd78f070c
✓ Published0🌍 Public
Aabernier
Last edited Sep 17, 2023
Created on Sep 17, 2023
This example demonstrates a text-generation workflow built with the Kit scripting framework and the `lorem-ipsum` library. It presents an interactive prompt that lets the user specify a count of paragraphs, sentences, or words, with live previews updating as choices are made. The code uses `arg` with custom flags for HTML formatting or copying output, and generates plain or HTML text via `loremIpsum()`. After selection, it either copies the generated text to the clipboard using `copy()` or replaces the selected text in the active editor with `setSelectedText()`.
AI-generated description