Client app: use in /base.mako, rework app init to use AMD definition