Hello Centerline,
I was actually working on a sample that takes the 3.x sample of adding shapefiles to the map (Add Shapefile) and converting it to 4.x. It currently only works when the shapefile has points and not polygons/polylines. I ran into some issues when trying to complete this though...
- There is currently a bug with esri/request where the query parameters does not get passed to the body when making a POST. To work around this you can use a different request API like Fetch.
Like I have said above, I have a working beta for shapefiles that include points. If you would like to use that as a starting point, feel free to let me know and I can send it to you.
Also, you mentioned client-side, the sample would need an Portal or ArcGIS Online for this to work since it uses the Generate operation.
EDIT: Looks like I actually got it to work. Here is the link to the code Sample of add shapefile. You do need AGOL or Portal for this to work. Also you may need the resource proxy to remedy any CORS errors you may get. This sample is based on the 3.x, so a lot of the code from that sample is the same with some changes for 4.x.