Update main.js

added namespace to require and linker function