Replace $keys/$modules by dict methods in js_objects.js and py_dom.js