Closed navarrorc closed 4 years ago
Hi @navarrorc and thanks for reporting. Might be a bug actually in PnPjs?
@tavikukko Thank you for creating an issue on the PnPjs repo. I will use the code that you provided when reporting the issue.
import { SPHttpClient } from "@pnp/sp";
(async () => {
const client = new SPHttpClient()
await client.delete(`https://tenant.sharepoint.com/sites/sitecollection/_api/web/lists/getbytitle('testlist')/fields/getbytitle('testcolumn')`)
})().catch(console.log)
Closing as the issue is in PnPjs. Thanks!
I can't delete a field from a List using the delete() function, in the console I get
TypeError: list.fields.getByTitle(...).delete is not a function
To reproduce:
Try to delete a field by following the instructions found at https://pnp.github.io/pnpjs/sp/fields/#delete-a-field