I've got a project initialized with:
algokit init --template tealscript
boxes.algo.ts:
import { Contract } from '@algorandfoundation/tealscript';
// eslint-disable-next-line no-unused-vars
class TestContract extends Contract {
items = BoxMap<bytes, bytes>();
notOkay(): void {
const item = this.items('test');
if (!item.exists) {
item.create(128);
}
}
allOkay(): void {
if (!this.items('test').exists) {
this.items('test').create(128);
}
}
}
> tealscript boxes.algo.ts
The code produced for notOkay is (all commented out):
// /*
// notOkay(): void {
// const item = this.items('test');
// if (!item.exists) {
// item.create(128);
// }
// }
I'm guessing the syntax isn't supported but there's no information about it in the IDE (VS Code) / the tealscript cmd.
I've got a project initialized with:
boxes.algo.ts:
> tealscript boxes.algo.tsThe code produced for
notOkayis (all commented out):I'm guessing the syntax isn't supported but there's no information about it in the IDE (VS Code) / the tealscript cmd.