Skip to content

Commit

Permalink
export inputs, outputs and configurables
Browse files Browse the repository at this point in the history
  • Loading branch information
nedsalk committed Dec 16, 2024
1 parent c280227 commit 05a613a
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/abi/src/gen/renderers/ts/templates/contract.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import type { InterfaceFunctionMapper, ProgramFunctionMapper } from '../common';
import { abi } from './{{name}}-abi';

export type {{name}}Types = Types;
export type {{name}}Configurables = Types['configurables'];

export class {{name}}Interface extends Interface {
declare functions: InterfaceFunctionMapper<Types['functions']>;
Expand Down
3 changes: 3 additions & 0 deletions packages/abi/src/gen/renderers/ts/templates/predicate.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ import { bytecode } from './{{name}}-bytecode';
import type { {{name}}Types as Types } from './{{name}}Types';

export type {{name}}Types = Types;
export type {{name}}Inputs = Types['inputs'];
export type {{name}}Output = Types['output'];
export type {{name}}Configurables = Types['configurables'];

export type {{name}}Parameters = Omit<
PredicateParams<
Expand Down
3 changes: 3 additions & 0 deletions packages/abi/src/gen/renderers/ts/templates/script.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ import { bytecode } from './{{name}}-bytecode';
import type { {{name}}Types as Types } from './{{name}}Types';

export type {{name}}Types = Types;
export type {{name}}Inputs = Types['inputs'];
export type {{name}}Output = Types['output'];
export type {{name}}Configurables = Types['configurables'];

export class {{name}} extends Script<
Types['inputs'],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import type { InterfaceFunctionMapper, ProgramFunctionMapper } from '../common';
import { abi } from './AbiContract-abi';

export type AbiContractTypes = Types;
export type AbiContractConfigurables = Types['configurables'];

export class AbiContractInterface extends Interface {
declare functions: InterfaceFunctionMapper<Types['functions']>;
Expand Down
3 changes: 3 additions & 0 deletions packages/fuel-gauge/src/abi/fixtures/predicates/predicate.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ import { bytecode } from './AbiPredicate-bytecode';
import type { AbiPredicateTypes as Types } from './AbiPredicateTypes';

export type AbiPredicateTypes = Types;
export type AbiPredicateInputs = Types['inputs'];
export type AbiPredicateOutput = Types['output'];
export type AbiPredicateConfigurables = Types['configurables'];

export type AbiPredicateParameters = Omit<
PredicateParams<
Expand Down
3 changes: 3 additions & 0 deletions packages/fuel-gauge/src/abi/fixtures/scripts/script.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ import { bytecode } from './AbiScript-bytecode';
import type { AbiScriptTypes as Types } from './AbiScriptTypes';

export type AbiScriptTypes = Types;
export type AbiScriptInputs = Types['inputs'];
export type AbiScriptOutput = Types['output'];
export type AbiScriptConfigurables = Types['configurables'];

export class AbiScript extends Script<
Types['inputs'],
Expand Down

0 comments on commit 05a613a

Please sign in to comment.