A purely nonlinear route to transition approaching the edge of chaos in a boundary layer