refactor JSGen
fix playground