Better javascript layout