# @ronin/syntax

> Allows for defining RONIN queries and schemas in code.

Latest version **0.2.44** (published 2025-06-15) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @ronin/syntax
pnpm add @ronin/syntax
yarn add @ronin/syntax
bun add @ronin/syntax
```

## Health

**Score 30/100 (F)** — status: maintenance-mode.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; pre 1.0.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.44 |
| Published | 2025-06-15 |
| First published | 2025-01-07 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | none |
| Module format | ESM |
| Dependencies | 0 |
| Unpacked size | 45 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | ronin |
| Maintainers | juriadams, leo, codenn, nurodev |
| Keywords | database, schema, primitives |

## Links

- npm: https://www.npmjs.com/package/@ronin/syntax
- npm.io page: https://npm.io/package/@ronin/syntax

## Alternatives

- [vest](https://npm.io/package/vest.md) — 50.1K weekly downloads
- [@regle/core](https://npm.io/package/@regle/core.md) — 47.0K weekly downloads
- [typeof-arguments](https://npm.io/package/typeof-arguments.md) — 12.5K weekly downloads
- [@lokalise/projects-engine-contracts](https://npm.io/package/@lokalise/projects-engine-contracts.md) — 978 weekly downloads
- [@osjwnpm/nam-laboriosam-quibusdam](https://npm.io/package/@osjwnpm/nam-laboriosam-quibusdam.md) — 70 weekly downloads

## Recent versions

- 0.2.44 (latest) — 2025-06-15
- 0.2.43-compiler-experimental-171 (compiler-experimental-171) — 2025-06-15
- 0.2.42-global-experimental-170 (global-experimental-170) — 2025-06-04
- 0.2.41-context-experimental-169 (context-experimental-169) — 2025-06-03
- 0.2.40-display-as-experimental-168 (display-as-experimental-168) — 2025-06-02
- 0.2.40-display-as-experimental-167 (display-as-experimental-167) — 2025-06-02
- 0.2.39-peer-deps-experimental-166 (peer-deps-experimental-166) — 2025-05-30
- 0.2.39-compiler-experimental-165 (compiler-experimental-165) — 2025-05-30
- 0.2.38-corny-json-extract-experimental-164 (corny-json-extract-experimental-164) — 2025-05-12
- 0.2.37-triggers-experimental-163 (triggers-experimental-163) — 2025-04-30
- 0.2.36-fix-result-record-type-experimental-162 (fix-result-record-type-experimental-162) — 2025-03-26
- 0.2.36-fix-result-record-type-experimental-161 (fix-result-record-type-experimental-161) — 2025-03-26
- 0.2.36-ben-ron-1099-experimental-160 (ben-ron-1099-experimental-160) — 2025-03-12
- 0.2.35-leo-ron-1113-experimental-159 (leo-ron-1113-experimental-159) — 2025-03-06
- 0.2.35-leo-ron-1113-experimental-158 (leo-ron-1113-experimental-158) — 2025-03-06
- … 162 more at https://npm.io/package/@ronin/syntax/versions

## README

# RONIN Syntax

[![tests](https://img.shields.io/github/actions/workflow/status/ronin-co/syntax/validate.yml?label=tests)](https://github.com/ronin-co/syntax/actions/workflows/validate.yml)
[![code coverage](https://img.shields.io/codecov/c/github/ronin-co/syntax)](https://codecov.io/github/ronin-co/syntax)
[![install size](https://packagephobia.com/badge?p=@ronin/syntax)](https://packagephobia.com/result?p=@ronin/syntax)

This package makes it possible to define [RONIN](https://ronin.co) queries and schemas in TypeScript code.

## Setup

You don't need to install this package explicitly, as it is already included in the [RONIN client](https://github.com/ronin-co/client).

However, we would be excited to welcome your feature suggestions or bug fixes for the RONIN schema. Read on to learn more about how to suggest changes.

## Contributing

To start contributing code, first make sure you have [Bun](https://bun.sh) installed, which is a JavaScript runtime.

Next, [clone the repo](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) and install its dependencies:

```bash
bun install
```

Once that's done, link the package to make it available to all of your local projects:

```bash
bun link
```

Inside your project, you can then run the following command, which is similar to `bun add @ronin/syntax` or `npm install @ronin/syntax`, except that it doesn't install `@ronin/syntax` from npm, but instead uses your local clone of the package:

```bash
bun link @ronin/syntax
```

If your project is not yet compatible with [Bun](https://bun.sh), feel free to replace all of the occurrences of the word `bun` in the commands above with `npm` instead.

You will just need to make sure that, once you [create a pull request](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request#creating-the-pull-request) on the current repo, it will not contain a `package-lock.json` file, which is usually generated by npm. Instead, we're using the `bun.lockb` file for this purpose (locking sub dependencies to a certain version).

### Transpilation

In order to be compatible with a wide range of projects, the source code of the `schema` repo needs to be compiled (transpiled) whenever you make changes to it. To automate this, you can keep this command running in your terminal:

```bash
bun run dev
```

Whenever you make a change to the source code, it will then automatically be transpiled again.

### Running Tests

The RONIN schema has 100% test coverage, which means that every single line of code is tested automatically, to ensure that any change to the source code doesn't cause a regression.

Before you create a pull request on the `schema` repo, it is therefore advised to run those tests in order to ensure everything works as expected:

```bash
# Run all tests
bun test

# Alternatively, run a single test
bun test -t 'your test name'
```

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