Say you have the general mappings $f: S\rightarrow T$ and $g: T\rightarrow U$. Wouldn't the notation $f: T\leftarrow S$ and $g: U\leftarrow T$ be more consistent with the right-to-left nature of composition, especially in light of how matrices are defined (taken as a linear mapping from a vector spaces $source$ to $target$, we say the height and width of the matrix is going to be $(\dim target \times \dim source)$). This convention makes chaining together matrix multiplications super straightforward, so I assume that's why it was historically chosen.
Is there a historical reason for this kind of mapping notation?