Small JavaScript semantic class extension.