refactored into js html and latex directories