obb

Akiz 2022-02-09T14:18:53.025839Z

Hi @borkdude, I am following your OBB example:

obb -e '(-> (js/Application "Safari") (.-documents) (aget 0) (.url))'
How do you know there is a documentsproperty? I cant find it in the applescript dictionary. Are there hidden, undocumented properties for every application? 🗿

borkdude 2022-02-09T14:23:35.048459Z

I guess you tried this? https://github.com/babashka/obb#explore-app-specific-apis I think I stole that example from @zane

👍 1
Akiz 2022-02-09T14:31:49.060029Z

Yeah, Ive done searching through Dictionary and i can find only its singular form - document. And Google Search has not helped me yet either.. But I am using Apple Scripting for first time, so…

borkdude 2022-02-09T14:33:22.811789Z

documents is the plural of document, I think *document* _n_ means there can be n (plural) in an array

👍 1
borkdude 2022-02-09T14:33:46.377159Z

that's just a wild guess

Akiz 2022-02-09T14:35:35.005029Z

And you are right 🎉🤦 I have just tested it with some other commands…

Akiz 2022-02-09T14:36:23.714739Z

Is this something common I havent seen till this day? I mean this form of a documentation…

borkdude 2022-02-09T14:37:09.670399Z

It's kind of special isn't it.