tachybase_todo/packages/plugins/@tachybase/plugin-todo-page/src/client/index.tsx
2024-10-17 19:41:45 +08:00

26 lines
545 B
TypeScript

import { Plugin } from '@tachybase/client';
import { TodoList } from './TodoList';
export class PluginTodoPageClient extends Plugin {
async afterAdd() {
// await this.app.pm.add()
}
async beforeLoad() {} // You can get and modify the app instance here
async load() {
this.router.add('todo', {
path: '/todo',
Component: TodoList,
});
this.app.pluginSettingsManager.add('todo', {
title: 'todo',
icon: 'ApiOutlined',
Component: TodoList,
});
}
}
export default PluginTodoPageClient;