You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
846 B
34 lines
846 B
import './less/index.less'; |
|
import '../i18n/i18n.cn'; |
|
import { createWidget, Layout, RouterWidget } from '@fui/core'; |
|
import { Main } from './main'; |
|
import { RouterDemo } from './center'; |
|
|
|
createWidget({ |
|
type: RouterWidget.xtype, |
|
routes: [ |
|
{ |
|
path: '/', |
|
component: function () { |
|
return Promise.resolve({ |
|
type: Layout.xtype, |
|
}); |
|
}, |
|
}, |
|
{ |
|
name: 'component', |
|
path: '/component/:componentId', |
|
component() { |
|
return Promise.resolve({ |
|
type: RouterDemo.xtype, |
|
}); |
|
}, |
|
}, |
|
], |
|
render() { |
|
return { |
|
type: Main.xtype, |
|
element: '#wrapper', |
|
}; |
|
}, |
|
});
|
|
|