| 12345678910111213141516171819202122232425 |
- "use strict";
- Object.defineProperty(exports, "__esModule", { value: true });
- exports.uniAppIOSMainPlugin = void 0;
- const uni_cli_shared_1 = require("@dcloudio/uni-cli-shared");
- function uniAppIOSMainPlugin() {
- const mainUTS = (0, uni_cli_shared_1.resolveMainPathOnce)(process.env.UNI_INPUT_DIR);
- return {
- name: 'uni:app-main',
- apply: 'build',
- async transform(code, id) {
- if ((0, uni_cli_shared_1.normalizePath)(id) === mainUTS) {
- return {
- code: `
- import './${uni_cli_shared_1.MANIFEST_JSON_UTS}'
- import './${uni_cli_shared_1.PAGES_JSON_UTS}'
- ${code}
- createApp().app.mount("#app");
- `,
- map: null,
- };
- }
- },
- };
- }
- exports.uniAppIOSMainPlugin = uniAppIOSMainPlugin;
|