As a new degree of freedom for optical manipulation, recently spatiotemporal optical vortices (STOVs) carrying transverse orbital angular momentums have been experimentally demonstrated with bulky optical systems. Here we propose a spatiotemporal differentiator to generate STOVs with pure transverse orbital angular momentum. In order to create phase singularity in the spatiotemporal domain, we design a spatiotemporal differentiator by breaking spatial mirror symmetry. In contrast to the complex bulky systems, the device we propose here is a simple one-dimensional periodic nanostructure and thus it is much more compact. We show that for a normal incident pulse, the differentiator generates a transmitted STOV pulse with transverse orbital angular momentum. Furthermore, we demonstrate that the interference of the generated STOVs can be used to detect the sharp changes of pulse envelopes, in both spatial and temporal dimensions.