-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Voxa 3 Project Generator #68
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just need to add this to the changelog.md
and add this command to help
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR diff size of 22336 lines exceeds the maximum allowed for the inline comments feature.
Code Climate has analyzed commit 7871bcd and detected 0 issues on this pull request. View more on Code Climate. |
* Create command to scaffold a basic TS Voxa app * Exclude templates folder * Exclude templates from lint * Add prettier ignore * Add initial template * Make JS and TS templates * Fix all errors in javascript template * Fix errors in typescript template * Add author prompt and format file * Create initial tests for file generation * Exclude generated tests from templates in npm test script * Exclude generated tests from templates in npm test-ci script * Set condition to get template files * Fix bugs and separate tests * Add analytics packages to templates * Generate code in the create command for analytics packages * Add test for analytics packages integration * Add message to prompt * Add Voxa CLI references to templates * Replace serverless prompt with voxa-cli * Create tests for voxa-cli integration * Exclude template views and interaction files from gitignore * Separate JS and TS project generation tests * Create store user info test cases * Add support to store user info in DynamoDB * Add save user info prompt * Add references to DynamoDB and users table in serverless file * Replicate dynamo config in serverless in JS project * Add support for Voxa platforms in templates * Create test cases for platform specifics * Set default value to Alexa when choosing a platform * Fix error in test cases in templates * Add yarn lock file in templates * Add missing space in README * Set instructions when the generator is done * Fix dashbot version * Remove analytics option and add suffix * Change final message to copy and paste commands more easily * Update dashbot and ga packages * Fix compilation errors for TS generated project * Refactor generator logic to its own class * Change handlebar variable names to match data * Set validation for prompts * Remove one empty line * Extract instructions messages to its own function * Add new generator feature to changelog
This add the functionality to the voxa-cli to scaffold a Voxa app project to just start coding your app instead of boilerplate code. This deprecate the Yeoman voxa generator which can only generate Voxa 2 projects.
Having this PR you'll be able to run
npx voxa create
and can generate a Voxa 3 project that:The best way to review this PR:
generator
branch.yarn run create
.By doing that it you can skip reviewing in here all files inside the templates directory (which takes like 98% of this PR) and just review the
create.ts
andVoxaGenerator.ts
file which are the command and class that will generate the Voxa project. You can also review the test files in case you'll like to know more about what the generator should generate based on the prompt answers.