externalizing js