I had the same problem. Here is what worked for me:
I changed:
import { IPropertyPaneConfiguration, PropertyPaneTextField } from '@microsoft/sp-property-pane';
import { BaseClientSideWebPart } from '@microsoft/sp-webpart-base';
to:
import { IPropertyPaneConfiguration, PropertyPaneTextField, BaseClientSideWebPart } from '@microsoft/sp-webpart-base';
and I changed:
protected get dataVersion(): Version {
return Version.parse('1.0');
}
to:
protected get dataVersion(): Version {
return Version.parse('1.1');
}
Then, I increased the WebPart version in package-solution.json
.
I think increasing the data version is the main reason it worked. However, I also deleted the app entirely before re-deploy:
- I removed the app from the site at
https://your-sitecollection.sharepoint.com/sites/your-site/_layouts/15/viewlsts.aspx
- I emptied the recycle bin at
https://your-sitecollection.sharepoint.com/sites/your-site/_layouts/15/AdminRecycleBin.aspx?ql=1
- I emptied the second-stage recycle bin at
https://your-sitecollection.sharepoint.com/sites/your-site/_layouts/15/AdminRecycleBin.aspx?View=2&ql=1
- I removed the app from the app catalog at
https://your-sitecollection.sharepoint.com/sites/appcatalog/AppCatalog/Forms/AllItems.aspx
- Finally, I installed and added the WebPart the usual way, again