isolate js to separated file