Convert between JS and Rust strings in a way that handles Unicode

This doesn't handle invalid UTF-16 and may not be efficient.  It's just a small
change to make things better until we decide what we're doing about strings in
the long run.

Fixes #1068.
Test non-ASCII tag names