Custom JavaScript parser