feat: 更新依赖版本,添加 cnb-board 环境检查功能
This commit is contained in:
@@ -3,6 +3,20 @@ import { getLiveMdContent } from './live/live-content.ts';
|
||||
import './cnb-dev-env.ts';
|
||||
import z from 'zod';
|
||||
import { execCommand } from '@/module/npm-install.ts';
|
||||
import { useKey } from '@kevisual/context';
|
||||
|
||||
app.route({
|
||||
path: 'cnb-board',
|
||||
key: 'is-cnb-board',
|
||||
description: '检查是否是 cnb-board 环境',
|
||||
middleware: ['auth-admin']
|
||||
}).define(async (ctx) => {
|
||||
const isCNB = useKey('CNB');
|
||||
ctx.body = {
|
||||
isCNB: !!isCNB,
|
||||
};
|
||||
}).addTo(app);
|
||||
|
||||
app.route({
|
||||
path: 'cnb-board',
|
||||
key: 'live',
|
||||
|
||||
Reference in New Issue
Block a user