Skip to content

Commit 72458fa

Browse files
emit deprecated standalone alias for local
1 parent c561884 commit 72458fa

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

cmd/crates/soroban-spec-typescript/src/boilerplate.rs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,21 @@ impl Project {
128128
NETWORK_PASSPHRASE_LOCAL => "local",
129129
_ => "unknown",
130130
};
131+
if network_passphrase == NETWORK_PASSPHRASE_LOCAL {
132+
return format!(
133+
r#"export const networks = {{
134+
local: {{
135+
networkPassphrase: "{network_passphrase}",
136+
contractId: "{contract_id}",
137+
}},
138+
/** @deprecated Use `local` instead. */
139+
standalone: {{
140+
networkPassphrase: "{network_passphrase}",
141+
contractId: "{contract_id}",
142+
}},
143+
}} as const"#
144+
);
145+
}
131146
format!(
132147
r#"export const networks = {{
133148
{network}: {{

0 commit comments

Comments
 (0)