First version of conversion from grammar to TypeScript
Support for optional properties