kit icon indicating copy to clipboard operation
kit copied to clipboard

Thoughts on platform-agnostic API interfaces?

Open mstine opened this issue 2 years ago • 2 comments

Hey, now that I'm up and running, this is fantastic.

First question: This obviously started out as a Mac-first platform, or at least that's how it looks from the number of Applescript-centric library functions I'm running into.

I wonder if it makes sense to have a platform-agnostic API for something like https://github.com/johnlindquist/kit/blob/main/src/lib/browser.ts that would figure out what platform you are on and then use the best available implementation...or appropriately error if no implementation was available.

If this is far-future stuff, no worries. Just curious if it's on the radar.

mstine avatar Jan 24 '23 19:01 mstine

@mstine Absolutely. The plan is to ditch all the AppleScript stuff in the future.

Ultimately, to interact with other apps (instead of AppleScript) the plan is to build extensions for other apps that can expose app state as .json files that Script Kit can read in. We started a discussion over here:

https://github.com/johnlindquist/kit/issues/662#issuecomment-1402006898

The SDK should then only contain all cross-platform tools.

johnlindquist avatar Jan 24 '23 19:01 johnlindquist

Sweet. I'll follow the discussion over there!

mstine avatar Jan 24 '23 20:01 mstine