Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
$ dnx gen controller --help
Finding the generator 'controller'...
Running the generator 'controller'...
Usage: controller [options]
Options:
--help|-h|-? Show help information
--useAsyncActions|-async Switch to indicate whether to generate async controller actions
--noViews|-nv Switch to indicate whether to generate CRUD views
--controllerName|-name Name of the controller
--restWithNoViews|-api Specify this switch to generate a Controller with REST style API, noViews is assumed and any view related options are ignored
--readWriteActions|-actions Specify this switch to generate Controller with read/write actions when a Model class is not used
--model|-m Model class to use
--dataContext|-dc DbContext class to use
--referenceScriptLibraries|-scripts Switch to specify whether to reference script libraries in the generated views
--layout|-l Custom Layout page to use
--useDefaultLayout|-udl Switch to specify that default layout should be used for the views
--force|-f Use this option to overwrite existing files
--relativeFolderPath|-outDir Specify the relative output folder path from project where the file needs to be generated, if not specified, file will be generated in the project folder
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment