Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/cute-steaks-dig.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@macalinao/codama-renderers-markdown": patch
---

Modify error code output format
14 changes: 14 additions & 0 deletions .changeset/every-trees-sip.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
"@macalinao/codama-instruction-accounts-dedupe-visitor": patch
"@macalinao/codama-nodes-from-anchor-x": patch
"@macalinao/codama-renderers-markdown": patch
"@macalinao/codama-renderers-js-esm": patch
"@macalinao/codama-rename-visitor": patch
"@macalinao/clients-kamino-lending": patch
"@macalinao/clients-token-metadata": patch
"@macalinao/clients-quarry": patch
"@macalinao/coda": patch
"coda-docs": patch
---

Update documentation
5 changes: 5 additions & 0 deletions .changeset/green-oranges-grab.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@macalinao/codama-instruction-accounts-dedupe-visitor": patch
---

Only apply deduping if necessary
6 changes: 6 additions & 0 deletions .changeset/sharp-mugs-design.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@macalinao/codama-renderers-markdown": minor
"@macalinao/codama-rename-visitor": minor
---

Refactor packages
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
run: bun install --frozen-lockfile

- name: Build all packages
run: bun run build
run: bun run build:ci

- name: Run linting
run: bun run lint
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
run: bun install --frozen-lockfile

- name: Build packages
run: bun run build
run: bun run build:ci

- name: Setup NPM authentication
run: |
Expand Down
1 change: 1 addition & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,7 @@ export default defineConfig({
- Arrays use shorthand syntax: `string[]` not `Array<string>`
- **Use double quotes for strings** (not single quotes)
- ES modules with `.js` extensions for imports
- **File naming**: Use kebab-case for all TypeScript files (e.g., `root-node-from-anchor.ts`, `create-codama-from-idls.ts`)

### After Making Code Changes
**Always run these commands to ensure code quality:**
Expand Down
49 changes: 24 additions & 25 deletions apps/docs/content/docs/examples.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -39,40 +39,39 @@ The Quarry client demonstrates Coda's **multi-program** capabilities:

Ideal for protocol developers managing multiple interconnected programs or anyone building comprehensive DeFi integrations.

## Add Your Example
### Kamino Lending Client

Using Coda in your project? We'd love to showcase it!
[![npm version](https://img.shields.io/npm/v/@macalinao/clients-kamino-lending.svg?style=flat-square)](https://www.npmjs.com/package/@macalinao/clients-kamino-lending)
[![npm downloads](https://img.shields.io/npm/dm/@macalinao/clients-kamino-lending.svg?style=flat-square)](https://www.npmjs.com/package/@macalinao/clients-kamino-lending)

**[Submit a Pull Request ](https://github.com/macalinao/coda/pulls)** to add your project to this documentation.
[View on GitHub ](https://github.com/macalinao/coda/tree/master/clients/kamino-lending)

### How to Add Your Example
The Kamino Lending client demonstrates Coda's ability to handle **complex IDLs with overlapping account names**:

1. Fork the [Coda repository](https://github.com/macalinao/coda)
2. Edit this file at `apps/docs/content/docs/examples.mdx`
3. Add your project following this format:
- **Overlapping account names** - Handles instructions with duplicate account names across nested structures
- **Automatic flattening** - Intelligently flattens nested account groups to avoid naming conflicts
- **Complex DeFi protocol** - Full lending protocol with deposit, withdraw, and liquidation operations
- **Production-scale IDL** - Processes large IDL with numerous instructions and account types

```mdx
### Your Project Name
This example is particularly useful for developers working with:

[View on GitHub →](https://github.com/yourname/yourproject)
- Complex DeFi protocols with nested account structures
- IDLs that have evolved over time with naming inconsistencies
- Programs requiring sophisticated account management patterns
- Large-scale production protocols with intricate instruction sets

Brief description of what makes your implementation unique:
The Kamino Lending client showcases how Coda's automatic account flattening feature (via `codama-instruction-accounts-dedupe-visitor`) resolves naming conflicts that would otherwise cause compilation errors in generated TypeScript code.

- **Key feature 1** - Description
- **Key feature 2** - Description
- **Key feature 3** - Description
## Add Your Example

What developers can learn from your example.
```
Using Coda in your project? We'd love to showcase it!

**[Submit a Pull Request →](https://github.com/macalinao/coda/pulls)** to add your project to this documentation.

4. Submit your PR with a clear description
### How to Add Your Example

We welcome examples that demonstrate:
- Novel configuration approaches
- Integration patterns
- Complex visitor usage
- Multi-program setups
- Custom code generation workflows
- Production deployment strategies
1. Fork the [Coda repository](https://github.com/macalinao/coda)
2. Edit this file at `apps/docs/content/docs/examples.mdx`
3. Submit your PR with a clear description

Help the Solana developer community by sharing your Coda implementation!
Help the Solana developer community by sharing your Coda implementation!
2 changes: 2 additions & 0 deletions apps/docs/content/docs/meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
"generating-clients",
"generating-docs",
"examples",
"---Packages---",
"packages",
"---Reference---",
"api"
]
Expand Down
Loading