Closed azzamsa closed 1 year ago
Hi.
I want to have my words sorted. I write this script in node, and it runs fine.
let text = "emacs nnn jq ShellCheck tidy neofetch stow workrave pandoc flameshot copyq"; let sorted = text .split(" ") .sort((a, b) => a.localeCompare(b)) .join(" "); console.log(sorted);
⬢ ❯ node sort.js copyq emacs flameshot jq neofetch nnn pandoc ShellCheck stow tidy workrave
But, when putting it in boop, I got the error below. RangeError. Internal Error. Icu error
RangeError. Internal Error. Icu error
/** { "api":1, "name":"Sort words", "description":"Sort words alphabetically", "author":"Azzam S.A (https://github.com/azzams)", "icon":"sort-characters", "tags":"sort,alphabet" } **/ function main(input) { input.text = input.text .replace(/\n$/, "") .split(" ") .sort((a, b) => a.localeCompare(b)) .join(" "); }
The issue is more suitable here: https://github.com/zoeyfyi/Boop-GTK/issues/397
Hi.
I want to have my words sorted. I write this script in node, and it runs fine.
But, when putting it in boop, I got the error below.
RangeError. Internal Error. Icu error