mirror of
https://github.com/tidys/cc-inspector-chrome
synced 2025-12-08 22:28:46 +00:00
代码整理
This commit is contained in:
70
cc-plugin.config.ts
Normal file
70
cc-plugin.config.ts
Normal file
@@ -0,0 +1,70 @@
|
||||
// @ts-ignore
|
||||
import { CocosPluginManifest, CocosPluginOptions, Panel } from "cc-plugin/src/declare";
|
||||
|
||||
const pkgName = "cc-inspector";
|
||||
|
||||
function i18n(key: string) {
|
||||
return `i18n:${pkgName}.${key}`;
|
||||
}
|
||||
|
||||
const manifest: CocosPluginManifest = {
|
||||
name: pkgName,
|
||||
version: "2.1.5",
|
||||
description: "Debug games made with CocosCreator and display node trees and node properties",
|
||||
author: "xu_yanfeng",
|
||||
main: "./src/main.ts",
|
||||
panels: [
|
||||
{
|
||||
name: "inspector",
|
||||
type: Panel.Type.DockAble,
|
||||
main: "./src/panel/index.ts",
|
||||
title: "Cocos 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",
|
||||
icon: {
|
||||
"48": "./icons/48.png",
|
||||
},
|
||||
analysis: {
|
||||
// googleAnalytics: "G-0S2X4Z1FE7",
|
||||
},
|
||||
chrome: {
|
||||
version: 3,
|
||||
pem: "./crx-key.pem",
|
||||
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/index.ts",
|
||||
script_content: "src/scripts/content/index.ts",
|
||||
script_inject: "src/scripts/inject/index.ts",
|
||||
script_inject_view: "src/scripts/inject-view/web-test.ts",
|
||||
},
|
||||
};
|
||||
const options: CocosPluginOptions = {
|
||||
obscure: true,
|
||||
server: {
|
||||
enabled: false,
|
||||
port: 2022,
|
||||
https: true,
|
||||
writeToDisk: true,
|
||||
},
|
||||
watchBuild: true,
|
||||
outputProject: {
|
||||
web: "./web",
|
||||
chrome: "./chrome",
|
||||
},
|
||||
};
|
||||
export default { manifest, options };
|
||||
Reference in New Issue
Block a user