// Delete one Asset
.addCase(deleteAssetThunk.fulfilled, (state, action) => {
state.assets = Object.fromEntries(Object.entries(state.assets).filter(([key]) => key !== action.payload))
console.log('fulfilled, asset Deleted');
})
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter