Spliting into seperate javascript blocks.