Skip to content

Commit

Permalink
docs: specify how nitrogen detect your specs (#14)
Browse files Browse the repository at this point in the history
* docs: specify how nitrogen detect your specs

Just small addition that makes integration clearer

* chore: fix typo
  • Loading branch information
jpudysz authored Aug 8, 2024
1 parent 4181c43 commit 7a914cf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/nitrogen/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,10 @@ Every nitro module must have a `nitro.json` file at it's root level (i.e. the fo

### 3. Create a TypeScript spec

The TypeScript spec is the single source of truth. It's interfaces, enums or other type declarations will be converted to C++ (or Swift/Kotlin) types using a code generator.
The TypeScript spec is the single source of truth. It's interfaces, enums or other type declarations will be converted to C++ (or Swift/Kotlin) types using a code generator. Nitrogen will run on all `*.nitro.ts` files relative to your `nitro.json` config.

```ts
// Image.nitro.ts
export interface Image extends HybridObject<{ ios: 'c++', android: 'c++' }> {
readonly width: number
readonly height: number
Expand Down

0 comments on commit 7a914cf

Please sign in to comment.