DataSet/DataLoader for timeseries data

I find timeseries data to be tricky since there are lots of small things to keep in mind to avoid look ahead biases. For example the data shoulc not be shuffled, train/validation split must be in order etc (im sure threre might be other things). The default DataLoader in pytouch seems to be defind not for timeseries data. Are there any examples of a good implementation of a custom DataSet and/or DataLoader for timeseries data and if not could someone knowledgeable provide one?