Ensure static and root is passed to edit.js

Fixes #1399.