hyperweb-io / hyperweb-io/ts-codegen

some messages are not objects but instead scalar values

Offen
#21 4 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
TypeScript
Sterne
126
Forks
31
Ø Merge
19 Min.
Gemergte PRs (30 T.)
2

Beschreibung

Here is the latest export for `ExecuteMsg` (in Typescript)

```js
export type ExecuteMsg = {
mint: {
[k: string]: unknown;
};
} | {
set_whitelist: {
whitelist: string;
[k: string]: unknown;
};
} | {
update_start_time: Timestamp;
} | {
update_per_address_limit: {
per_address_limit: number;
[k: string]: unknown;
};
} | {
mint_to: {
recipient: string;
[k: string]: unknown;
};
} | {
mint_for: {
recipient: string;
token_id: number;
[k: string]: unknown;
};
} | {
withdraw: {
[k: string]: unknown;
};
};
```

I noticed that `update_start_time` is the only one that doesn't take an object. Every other message uses either an empty object or an object with props.

```
update_start_time: Timestamp
```

Is there a convention? Or should we account for this in the cosmwasm-typescript-gen

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Rechercherichtung

Start by tracing how cosmwasm-typescript-gen handles ExecuteMsg variants, comparing the scalar update_start_time value with the object-shaped messages shown in the report. Done means the generator either represents scalar message values correctly and consistently, or clearly documents the convention it follows.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
typescript
Bereich
tooling
Issue-Typ
Bug
Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.