SOLVED

SPFx webparts and forms

%3CLINGO-SUB%20id%3D%22lingo-sub-73005%22%20slang%3D%22en-US%22%3ESPFx%20webparts%20and%20forms%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-73005%22%20slang%3D%22en-US%22%3E%3CP%3EI'm%20developing%20a%20SPFx%20web%20part%20that%20reads%20data%20form%20SharePoint%20and%20then%20displays%20this%20in%20the%20web%20part%20that%20looks%20a%20bit%20like%20an%20edit%20form.%20So%20I'm%20using%20fields%20like%20dropdowns%2C%20single%20line%20text%20fields%20etc.%20I%20noticed%20that%20in%20SPFx%20classes%20for%20dropdowns%20etc%20exist%20for%20the%20web%20part%20property%20pane%2C%20but%20I%20couldn't%20find%20anything%20for%20fields%20within%20the%20web%20part%20itself%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWe%20can%20of%20course%20use%20the%20render%20methods%20to%20generate%20the%20html%20that%20is%20required%20but%20if%20there%20is%20something%20there%20that%20I%20should%20reuse%20then%20that%20would%20have%20my%20preference.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHas%20anybody%20looked%20into%20this%3F%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-73005%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EDeveloper%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-76173%22%20slang%3D%22en-US%22%3ERe%3A%20SPFx%20webparts%20and%20forms%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-76173%22%20slang%3D%22en-US%22%3E%3CP%3EMy%20blog%20articles%20on%20this%20are%20still%20work%20in%20progress%2C%20but%20a%20lot%20of%20it%20is%20there%20now%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fveenstra.me.uk%2F2017%2F06%2F05%2Foffice-365-sharepoint-how-to-create-forms-using-spfx%2F%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fveenstra.me.uk%2F2017%2F06%2F05%2Foffice-365-sharepoint-how-to-create-forms-using-spfx%2F%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
MVP

I'm developing a SPFx web part that reads data form SharePoint and then displays this in the web part that looks a bit like an edit form. So I'm using fields like dropdowns, single line text fields etc. I noticed that in SPFx classes for dropdowns etc exist for the web part property pane, but I couldn't find anything for fields within the web part itself?

 

We can of course use the render methods to generate the html that is required but if there is something there that I should reuse then that would have my preference.

 

Has anybody looked into this? 

1 Reply
best response confirmed by Pieter Veenstra (MVP)
Solution

My blog articles on this are still work in progress, but a lot of it is there now:

 

https://veenstra.me.uk/2017/06/05/office-365-sharepoint-how-to-create-forms-using-spfx/