Skip to content

Commit

Permalink
📱
Browse files Browse the repository at this point in the history
  • Loading branch information
Vanessa219 committed May 16, 2023
1 parent a335101 commit 2750a1b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/src/layout/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down
6 changes: 5 additions & 1 deletion app/src/plugin/loader.ts
Original file line number Diff line number Diff line change
@@ -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 = {
Expand Down Expand Up @@ -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
};

0 comments on commit 2750a1b

Please sign in to comment.