fix(GOV-009): 消除前端运行时模板警告
This commit is contained in:
@@ -21,5 +21,6 @@ describe('应用外壳', () => {
|
||||
expect(wrapper.get('header').attributes('aria-label')).toBe('应用导航');
|
||||
expect(wrapper.get('main').attributes('id')).toBe('main-content');
|
||||
expect(wrapper.text()).toContain('A 股市场分析工具');
|
||||
expect(wrapper.text()).toContain('工程基线已就绪');
|
||||
});
|
||||
});
|
||||
|
||||
@@ -4,13 +4,15 @@ import {
|
||||
type RouterHistory,
|
||||
type RouteRecordRaw,
|
||||
} from 'vue-router';
|
||||
import { h } from 'vue';
|
||||
|
||||
const routes: RouteRecordRaw[] = [
|
||||
{
|
||||
path: '/',
|
||||
name: 'home',
|
||||
component: {
|
||||
template: '<section aria-label="应用就绪"><p>工程基线已就绪</p></section>',
|
||||
// 工程基线不引入运行时模板编译器;业务首页落地前用渲染函数提供可观测占位内容。
|
||||
render: () => h('section', { 'aria-label': '应用就绪' }, [h('p', '工程基线已就绪')]),
|
||||
},
|
||||
},
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user