Basic crafts on javascript