rewrote charorder plugin to pure Javascript and passed unit tests