About pipeline and splitting data

Should we first split the data AND then perform pipeline or first pipeline and then split the data?