This commit is contained in:
Vanessa 2023-05-16 18:49:12 +08:00
parent a335101d49
commit 2750a1b86f
2 changed files with 6 additions and 2 deletions

View file

@ -3,7 +3,7 @@ import {genUUID} from "../util/genID";
import {addResize, resizeTabs} from "./util";
/// #if MOBILE
// 检测移动端是否引入了桌面端的代码
alert("Need remove unused code");
debugger;
/// #endif
export class Layout {

View file

@ -1,8 +1,10 @@
import {fetchPost} from "../util/fetch";
import {App} from "../index";
import {Plugin} from "./index";
import {API} from "./API";
/// #if !MOBILE
import {exportLayout} from "../layout/util";
/// #endif
import {API} from "./API";
const getObject = (key: string) => {
const api = {
@ -97,9 +99,11 @@ export const loadPlugin = (app: App, item: IPluginData) => {
const styleElement = document.createElement("style");
styleElement.textContent = item.css;
document.head.append(styleElement);
/// #if !MOBILE
exportLayout({
reload: false,
onlyData: false,
errorExit: false
});
/// #endif
};