Description
Category
- Question
- Typo
- Bug
- Additional article idea
Expected or Desired Behavior
Using @microsoft/sharepoint yoeman generator, one should be able to create SP2016 onprem project using spfx with the generated node modules and other files.
Observed Behavior
After installing @microsoft/sharepoint yoeman generator, by running yo @microsoft/sharepoint
and giving required answers to the prompts for setting up a sample 2016 onprem sharepoint project with react, a project is created with few warnings and following message :
added 1717 packages from 1678 contributors and audited 106412 packages in 1455.394s
found 617 vulnerabilities (249 low, 160 moderate, 203 high, 5 critical)
After running gulp trust-dev-cert
,
I ran gulp serve
, at this time the command execution is initiated and suddenly stopped with few errors.
Build target: DEBUG
[11:14:18] Using gulpfile ~\Jeevan Desktop\Sample\gulpfile.js
[11:14:18] Starting gulp
[11:14:18] Starting 'serve'...
[11:14:18] Starting subtask 'pre-copy'...
[11:14:18] Finished subtask 'pre-copy' after 94 ms
[11:14:18] Starting subtask 'copy-static-assets'...
[11:14:18] Starting subtask 'sass'...
[11:14:26] Finished subtask 'copy-static-assets' after 8.54 s
[11:14:26] Finished subtask 'sass' after 8.53 s
[11:14:26] Starting subtask 'tslint'...
[11:14:26] Starting subtask 'typescript'...
[11:14:26] [typescript] TypeScript version: 2.2.2
[11:14:30] Error - typescript - src\webparts\helloWorld\HelloWorldWebPart.ts(7,7): error TS2307: Cannot find module '@microsoft/sp-property-pane'.
[11:14:32] Warning - tslint - src\webparts\helloWorld\components\HelloWorld.tsx(16,23): error quotemark: " should be '
[11:14:32] Finished subtask 'tslint' after 5.42 s
[11:14:32] Error - 'typescript' sub task errored after 5.52 s "TypeScript error(s) occurred."
[11:14:32] 'serve' errored after 14 s
[11:14:32]
[11:14:32] ==================[ Finished ]==================
Warning - tslint - src\webparts\helloWorld\components\HelloWorld.tsx(16,23): error quotemark: "should be '
Error - typescript - src\webparts\helloWorld\HelloWorldWebPart.ts(7,7): error TS2307: Cannot find module '@microsoft/sp-property-pane'.
Error - 'typescript' sub task errored after 5.52 s "TypeScript error(s) occurred."
[11:14:33] Project sample version: 0.0.1
[11:14:33] Build tools version: 2.5.3
[11:14:33] Node version: v8.15.1
[11:14:33] Total duration: 25 s
[11:14:33] Task warnings: 1
[11:14:33] Task errors: 2
Steps to Reproduce
- npm install -g yo gulp
- npm i @microsoft/sharepoint
- yo @microsoft/sharepoint
- answer prompts for SP2016 onprem webPart with react
- gulp trust-dev-cert
- gulp serve
Request :
Kindly please share steps to setup SP2016 onprem with React, without errors.