modify fold sytnx and add javascript