Yeoman generator to kickstart your Power Apps Component Framework project.
npm install generator-pcf
C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\15.0\Bin\
`
or maybe if you have Visual Studio 2019:
`
C:\Program Files (x86)\Microsoft Visual Studio\2019\Preview\MSBuild\Current\Bin
`
Usage
First, install Yeoman and generator-pcf using npm (we assume you have pre-installed node.js).
`bash
npm install -g yo
npm install -g generator-pcf
`
Then generate your new project by answering the prompts:
`bash
yo pcf --force
`
or just passing the command line arguments:
`bash
yo pcf --ns Fic --n SuperCoolControl --t field --pkg 2 --pp fic --pn IvanFicko --force
`
Options
| Name | Alias | Type | Description | Required | Default |
| ------------------- | ----- | ------ | ------------------------------------------------------------ | -------- | --------- |
| skip-msbuild | sb | bool | Do not run MSBuild at end | NO | false |
| skip-solution | ss | bool | Do not create CDS soution project | NO | false |
| force | | bool | Overwrite all files | NO | false |
| controlNamespace | ns | string | Control Namespace | NO | undefined |
| controlName | n | string | Control name | NO | undefined |
| controlTemplate | t | string | Choose control template:- field
- dataset
| NO | undefined |
| npmPackage | pkg | int | Additional NPM packages:- 0 = None
- 1 = React
- 2 = React + Fluent UI
| NO | undefined |
| publisherPrefix | pp | string | Publisher prefix for solution | NO | undefined |
| publisherName | pn | string | Publisher name for solution | NO | undefined |
| solutionPackageType | spt | string | Solution type that will be created after msbuild command | NO | undefined |
\* All options that will be undefined will result in a prompt for that value
Sub-generators
| Name | Description |
| -------------------------------- | ---------------------------------------------------- |
| resx | Adding RESX files to your project. |
| readme | Generates README file based on control metadata. |
| github-action | Generates GitHub Actions Workflow file for the repo. |
Features
- Creates basic PCF project like Power Apps CLI
- Adds sample files (RESX, CSS, preview image, ...)
- Installs additional NPM dependencies
- Initializes Power Apps solution
Release notes
$3
- Enhancements
- Added support for virtual components with React/Fluent UI
$3
- Features
- Added option to use source maps
- Bugfixes
- Fixed .eslintrc.json settings for TypeScript
$3
- Features
- Added featureconfig.json file in the project initialization
$3
- Bugfixes
- Fixed publisher display name in solution XML
$3
- Bugfixes
- Fixed typo in warning message when MSBuild is not found in path variable
- Other
- Added Azure App Insights tracking for events
$3
- Bugfixes
- Fixed bug with path when adding solution reference to a project file
$3
- Enhancements
- GitHub action now supports creating the release by manual execution
- You can now define which solution type will be created after executing the build command
$3
- Other
- Removed custom manifest XML templates, it's now using XMLs created by the Power Apps CLI
- Changed manifest XML editing logic
$3
- Features
- You can now generate GitHub action for automatic release creation by calling pcf:github-action sub-generator
- Other
- Changed solution folder structure to from Solutions to Solution/