JS sidebar directive init