use snippets instead of hardcoded code in the generator