# danger-ts

> An npx-able mix of Danger and TypeScript, so you can trivially use Danger JS with a TS Dangerfile without having Danger in your dependency tree.

Latest version **1.0.0** (published 2020-08-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install danger-ts
pnpm add danger-ts
yarn add danger-ts
bun add danger-ts
```

Provides the command `danger-ts`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2020-08-19 |
| First published | 2020-08-19 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 2.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 6 |
| Author | Orta Therox |
| Maintainers | orta |

## Links

- npm: https://www.npmjs.com/package/danger-ts
- Repository: https://github.com/danger/danger-ts
- Homepage: https://github.com/danger/danger-ts#readme
- Issues: https://github.com/danger/danger-ts/issues
- npm.io page: https://npm.io/package/danger-ts

## Dependencies (2)

- [danger](https://npm.io/package/danger.md) *
- [typescript](https://npm.io/package/typescript.md) *

## Recent versions

- 1.0.0 (latest) — 2020-08-19
- 0.0.1 — 2020-08-19

## README

# danger-ts

An npx-able mix of Danger and TypeScript, so you can trivially use Danger JS with a TS Dangerfile without having Danger in your dependency tree.  

```sh
echo 'import {markdown} from "danger"; markdown("Hi!");"' > dangerfile.ts

npx danger-ts
```

### Why Use This?

Most of the time, you don't need to. You could be using Danger in a TS project, at that point though you'll want to include the Danger dep for the Types. 

Cases where you might not though:

- You're running CI on webhooks which aren't worth doing a full `yarn install` on. 
- You add the `dangerfile.ts` to your `exclude` in the project's `tsconfig.json`.

In those cases you can use `npx danger-ts` which acts as a proxy for `yarn danger ci`.

e.g.

```yml
name: CI
on: pull_request

jobs:
  test:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v1
      - uses: actions/setup-node@v1

      - name: "Use npx to run the dangerfile"
        run: "npx danger-ts"
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
```

---
_Source: https://npm.io/package/danger-ts · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
