Open goldbergyoni opened 2 years ago
Why not use tools like yeoman
or plopjs
?
Because we want to have full control. I've tried plopjs, it's great for simple and quick skeleton. We're different - A robust generator that might end with some complex logic. Consider replacing the express layer with fastify layer. Also, plopjs is based on templating - the issue explains why templating won't work for us
Yeoman is the front DX which the developer uses, we want to have our own UI/DX/CLI. You can tweak it but it never built to serve as the back layer.
Does it make sense?
Yes. Must say that it sounds like a package by itself, and we may want separate it to another repo
🎯 Goal: - Currently our code generator does almost nothing but copying the code-templates folder to the destination as-is. We need to perform some logic to support future cases (e.g. remove some code blocks). We should code a small module that performs this logic during code generation
For a start, we should support:
🤔 Things to consider:
🏭 Proposed design: - Our code generator should act on .ts files, apply its logic based on custom code and identify areas of change using regex/comments