Example Code on how to implement a Functional Component with Hooks in a SharePoint Framework (SPFx) Webpart
Get your own free development tenant by subscribing to Microsoft 365 developer program
Solution | Author(s) |
---|---|
spfx-react-hooks-demo | Rob Pearmain (www.yorcloud.com) |
Version | Date | Comments |
---|---|---|
1.0 | January 29, 2021 | Initial release |
THIS CODE IS PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.
- Clone this repository
- Ensure that you are at the solution folder
- in the command-line run:
- npm install
- gulp serve
This webpart illustrates the following concepts:
- React Functional Components
- React Hooks
- Getting started with SharePoint Framework
- Building for Microsoft teams
- Use Microsoft Graph in your solution
- Publish SharePoint Framework applications to the Marketplace
- Microsoft 365 Patterns and Practices - Guidance, tooling, samples and open-source controls for your Microsoft 365 development