Use appendChild instead of insertBefore for a small perfomance boost

- Fixes #11