TextField required: Property "required" does not exist
Bug Report
- Package version(s):^4.23.0
Priorities and help requested (not applicable if asking question):
Are you willing to submit a PR to fix? (No)
Requested priority: (Normal)
Products/sites affected: (if applicable) MS BLIS
Describe the issue:
Following the example in the documentation (see below) and getting the error shown above
<TextField
required={ true }
onChanged={this.contentChanged.bind(this)}
label="Payload"
placeholder="Payload..."
value={this.state.contentVal} />
Actual behavior:
getting the error shown above (Property "required" does not exist)
Expected behavior:
should work like the sample
Have you tried this with 4.31.0? We had a rough patch with typings mismatch. There shouldn't be anything wrong with the textfield required property.
Hi @micahgodbolt ,
I have met this problem as well, and my version of office-ui-fabric-react is 4.31.0.
not only 'required'. This problem is also happened to 'name' and 'placeholder'.
In my case that was only an intellisense problem, since visual studio was using Typescript 2.2 for the intellisense, but wepack was really using the 2.4 version for the real transpiling process. All the properties that showed errors where defined in "d.ts" files from the 2.2 version.
The problem arised a few days ago (when the typing changed?). Then I realized I was still using TS 2.2, my solution was:
- Installed latest typescript version.
- Changed Visual Studio's intellisense settings to use 2.4 as explained here: https://github.com/Microsoft/TypeScript/wiki/Updating-TypeScript-in-Visual-Studio-2017 and got not more intellisense problems.
Hope it helps!
Closing, please reply if any issues remain