Skids

i have seen it done before in a tutorial which i cant find anymore.
what they did is that;

  1. when space is pressed it begins a lineTo from the point of an object resembling the back left wheel.

  2. from there it continues the lineTo making a realistic skid.

  3. after a small amount of time the skids deletes.

Any ideas how to acheive this?