Display User Author Details in Block UserProfile I am looking to display my own block on user profile page. The block will to display the username of the user whom profile we are viewing. 

I went ahead and created a view, show users, block. 

Added contextual filter for UIID, Raw value from URL. 
Path component 2

User profile and a user sub-pages have this structure: 
domain.com/u/username (user main profile page)
domain.com/user/845/posts (user posts, where 845 is uid)

How can I add a contextual filter that will work on both cases? The username is changed a little by path auto. Dashes, commas, uppercases and such are removed so that may be why raw value from URL is not working. 

Btw, I am open to creating a custom user profile by creating user/% view for user profile.
The alias doesn't matter, you get the argument for a contextual filter from the internal path, no matter if the URL in the browser was aliased (unless you enable the option "Use path alias"). For a user profile the internal path is /user/[uid]. 

For the user ID there is also a contextual filter "User ID from route context", this filter is able to get the user without specifying in which path position it is.