added defer to local scripts