An open API service indexing awesome lists of open source software.

https://github.com/magicdawn/txa

TypeScript for Automation, aka osascript -l TypeScript
https://github.com/magicdawn/txa

Last synced: 6 months ago
JSON representation

TypeScript for Automation, aka osascript -l TypeScript

Awesome Lists containing this project

README

          

# txa

> TypeScript for Automation, aka `osascript -l TypeScript`

>
> TXA means "TypeScript for Automation" just like [JXA](https://github.com/JXA-Cookbook/JXA-Cookbook/wiki): "JavaScript for Automation"

[![npm version](https://img.shields.io/npm/v/txa.svg?style=flat-square)](https://www.npmjs.com/package/txa)
[![npm downloads](https://img.shields.io/npm/dm/txa.svg?style=flat-square)](https://www.npmjs.com/package/txa)
[![npm license](https://img.shields.io/npm/l/txa.svg?style=flat-square)](http://magicdawn.mit-license.org)

## Install

```sh
$ pnpm add -g txa
```

## Usage

### `txa `

bundle and execute a file, ES module can be used

use as Shebang

```ts
#!/usr/bin/env txa
```

### `txa build `

bundle file to output, output can be a dir or a js file

## Tips

### types

```sh
# install
$ pnpm add -D @jxa/globle-type
```

then use `reference` so you get editor intellisense

```ts
///
```

### eslint

```js
/* eslint-env applescript */
```

## Changelog

[CHANGELOG.md](CHANGELOG.md)

## License

the MIT License http://magicdawn.mit-license.org