cc-inspector-chrome/cc-inspector/cc-plugin.config.ts

65 lines
1.4 KiB
TypeScript
Raw Normal View History

2024-01-05 13:48:16 +08:00
// @ts-ignore
import {
CocosPluginManifest,
CocosPluginOptions,
Panel,
PluginType,
} from "cc-plugin/src/declare";
const pkgName = "cc-inspector";
function i18n(key: string) {
return `i18n:${pkgName}.${key}`;
}
const manifest: CocosPluginManifest = {
name: pkgName,
2024-01-05 16:45:23 +08:00
version: "2.1.0",
description: "cc-inspector desc",
2024-01-05 13:48:16 +08:00
author: "xu_yanfeng",
main: "./src/main.ts",
panels: [
{
name: "main",
type: Panel.Type.DockAble,
main: "./src/panel/index.ts",
title: "cc-inspector",
width: 500,
height: 400,
minWidth: 50,
minHeight: 400,
},
],
menus: [
{
path: `cc-inspector/${i18n("title")}`,
message: {
name: "showPanel",
},
},
],
i18n_en: "./src/i18n/en.ts",
i18n_zh: "./src/i18n/zh.ts",
chrome: {
2024-01-05 16:45:23 +08:00
view_devtools: "src/views/devtools/index.ts",
view_options: "src/views/options/index.ts",
view_popup: "src/views/popup/index.ts",
script_background: "src/scripts/background.ts",
script_content: "src/scripts/content.ts",
script_inject: "src/scripts/inject.ts",
2024-01-05 13:48:16 +08:00
},
};
// 这里的options变量名暂时不支持修改发布时会进行必要的修改
const options: CocosPluginOptions = {
server: {
enabled: true,
port: 2022,
},
watchBuild: true,
outputProject: {
web: "./web",
2024-01-05 16:45:23 +08:00
chrome: "./chrome",
2024-01-05 13:48:16 +08:00
},
};
export default { manifest, options };