eddev 0.1.33-beta-7 → 0.1.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/blocks/installGutenbergHooks.js +4 -0
- package/build/clean.d.ts +1 -0
- package/build/clean.js +60 -0
- package/build/create-codegen-worker.d.ts +1 -2
- package/build/create-codegen-worker.js +5 -5
- package/build/create-webpack-worker.d.ts +1 -2
- package/build/create-webpack-worker.js +8 -4
- package/build/get-webpack-config.d.ts +1 -10
- package/build/get-webpack-config.js +1 -1
- package/build/state/codegen-state.d.ts +5 -0
- package/build/state/compiler-state.d.ts +11 -0
- package/build/workers/codegen-worker-script.d.ts +1 -4
- package/build/workers/codegen-worker-script.js +1 -1
- package/build/workers/webpack-worker-script.d.ts +1 -1
- package/build/workers/webpack-worker-script.js +6 -1
- package/cli/build.dev.d.ts +2 -0
- package/cli/build.dev.js +38 -26
- package/cli/build.prod.js +6 -2
- package/cli/cli.js +4 -0
- package/cli/display/components/BundleDisplay.d.ts +0 -1
- package/cli/display/components/CodegenDisplay.d.ts +0 -1
- package/cli/display/components/DevCLIDisplay.d.ts +0 -1
- package/cli/display/components/StatusIcon.d.ts +0 -1
- package/components/AdminBar.d.ts +0 -1
- package/entry/Root.d.ts +0 -1
- package/package.json +1 -1
- package/style/createStitches.d.ts +0 -1
|
@@ -74,6 +74,10 @@ function installEDGutenbergHooks() {
|
|
|
74
74
|
item.supports.customClassName = false;
|
|
75
75
|
item.edit = function (props) {
|
|
76
76
|
var self = this;
|
|
77
|
+
(0, react_1.useEffect)(function () {
|
|
78
|
+
// @ts-ignore
|
|
79
|
+
window.wp.data.dispatch("core/block-editor").setTemplateValidity(true);
|
|
80
|
+
}, []);
|
|
77
81
|
return ((0, jsx_runtime_1.jsx)(BlockContext.Provider, __assign({ value: { name: name, props: props } }, { children: (0, jsx_runtime_1.jsx)(blockAttributes_1.InlineEditingContextProvider, __assign({ values: props.attributes.inline || {}, innerBlocks: props.innerBlocks, onChange: function (attrs) {
|
|
78
82
|
props.setAttributes(__assign(__assign({}, props.attributes), { inline: attrs }));
|
|
79
83
|
} }, { children: edit_1.call(self, props) }), void 0) }), void 0));
|
package/build/clean.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function cleanOutput(): Promise<void>;
|
package/build/clean.js
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
12
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
13
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
14
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
15
|
+
function step(op) {
|
|
16
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
17
|
+
while (_) try {
|
|
18
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
19
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
20
|
+
switch (op[0]) {
|
|
21
|
+
case 0: case 1: t = op; break;
|
|
22
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
23
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
24
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
25
|
+
default:
|
|
26
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
27
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
28
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
29
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
30
|
+
if (t[2]) _.ops.pop();
|
|
31
|
+
_.trys.pop(); continue;
|
|
32
|
+
}
|
|
33
|
+
op = body.call(thisArg, _);
|
|
34
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
35
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
39
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
40
|
+
};
|
|
41
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
42
|
+
exports.cleanOutput = void 0;
|
|
43
|
+
var rimraf_1 = __importDefault(require("rimraf"));
|
|
44
|
+
var path_1 = require("path");
|
|
45
|
+
function cleanOutput() {
|
|
46
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
47
|
+
return __generator(this, function (_a) {
|
|
48
|
+
switch (_a.label) {
|
|
49
|
+
case 0: return [4 /*yield*/, new Promise(function (resolve) { return (0, rimraf_1.default)((0, path_1.join)(process.cwd(), "dist/frontend"), resolve); })];
|
|
50
|
+
case 1:
|
|
51
|
+
_a.sent();
|
|
52
|
+
return [4 /*yield*/, new Promise(function (resolve) { return (0, rimraf_1.default)((0, path_1.join)(process.cwd(), "dist/admin"), resolve); })];
|
|
53
|
+
case 2:
|
|
54
|
+
_a.sent();
|
|
55
|
+
return [2 /*return*/];
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
exports.cleanOutput = cleanOutput;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
import { Observable } from "../utils/Observable";
|
|
2
|
-
import { CodegenOptions } from "./
|
|
3
|
-
import { CodegenState } from "./state/codegen-state";
|
|
2
|
+
import { CodegenOptions, CodegenState } from "./state/codegen-state";
|
|
4
3
|
export declare function createCodegenWorker(opts: CodegenOptions): Observable<CodegenState>;
|
|
@@ -45,26 +45,26 @@ function createCodegenWorker(opts) {
|
|
|
45
45
|
});
|
|
46
46
|
worker.on("message", function (data) {
|
|
47
47
|
if (data.code === "ready") {
|
|
48
|
-
subject.update(function (state) { return (__assign(__assign({}, state), { status: "ready", log: "", duration: 0, errors: [] })); });
|
|
48
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { status: "ready", log: opts.retainLog ? state.log : "", duration: 0, errors: [] })); });
|
|
49
49
|
}
|
|
50
50
|
else if (data.code === "fetching") {
|
|
51
|
-
subject.update(function (state) { return (__assign(__assign({}, state), { status: "fetching", log: "", duration: 0, errors: [] })); });
|
|
51
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { status: "fetching", log: opts.retainLog ? state.log : "", duration: 0, errors: [] })); });
|
|
52
52
|
}
|
|
53
53
|
else if (data.code === "generating") {
|
|
54
|
-
subject.update(function (state) { return (__assign(__assign({}, state), { status: "generating", errors: [], duration: 0, log: "" })); });
|
|
54
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { status: "generating", errors: [], duration: 0, log: opts.retainLog ? state.log : "" })); });
|
|
55
55
|
}
|
|
56
56
|
else if (data.code === "error") {
|
|
57
57
|
subject.update(function (state) { return (__assign(__assign({}, state), { status: "error", statusLabel: "", duration: 0, reason: undefined, errors: data.errors })); });
|
|
58
58
|
}
|
|
59
59
|
else if (data.code === "success") {
|
|
60
|
-
subject.update(function (state) { return (__assign(__assign({}, state), { status: "success", duration: data.duration, reason: data.reason, errors: [], log: "" })); });
|
|
60
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { status: "success", duration: data.duration, reason: data.reason, errors: [], log: opts.retainLog ? state.log : "" })); });
|
|
61
61
|
}
|
|
62
62
|
else if (data.code === "invalidated") {
|
|
63
63
|
subject.update(function (state) { return (__assign(__assign({}, state), { status: "invalidated", reason: data.reason, duration: 0 })); });
|
|
64
64
|
}
|
|
65
65
|
});
|
|
66
66
|
worker.on("exit", function () {
|
|
67
|
-
subject.update(function (state) { return (__assign(__assign({}, state), { status: "success", log: "" })); });
|
|
67
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { status: "success", log: opts.retainLog ? state.log : "" })); });
|
|
68
68
|
});
|
|
69
69
|
return subject;
|
|
70
70
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { WebpackWorkerOptions } from "./get-webpack-config";
|
|
2
1
|
import { Observable } from "../utils/Observable";
|
|
3
|
-
import { CompilerState } from "./state/compiler-state";
|
|
2
|
+
import { CompilerState, WebpackWorkerOptions } from "./state/compiler-state";
|
|
4
3
|
export declare function createWebpackWorker(opts: WebpackWorkerOptions): Observable<CompilerState>;
|
|
@@ -27,7 +27,11 @@ function createWebpackWorker(opts) {
|
|
|
27
27
|
subject.update(function (state) { return (__assign(__assign({}, state), { log: (state.log || "") + chunk })); });
|
|
28
28
|
});
|
|
29
29
|
worker.stdout.on("data", function (chunk) {
|
|
30
|
-
|
|
30
|
+
var str = chunk.toString();
|
|
31
|
+
if (str.includes("Project is running at") || str.includes("webpack output is served from")) {
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { log: (state.log || "") + str })); });
|
|
31
35
|
});
|
|
32
36
|
var subject = new Observable_1.Observable({
|
|
33
37
|
title: opts.title,
|
|
@@ -38,18 +42,18 @@ function createWebpackWorker(opts) {
|
|
|
38
42
|
});
|
|
39
43
|
worker.on("message", function (data) {
|
|
40
44
|
if (data.code === "compiling") {
|
|
41
|
-
subject.update(function (state) { return (__assign(__assign({}, state), { status: "compiling", statusLabel: state.status === "compiling" ? state.statusLabel : "", log: "", duration: 0, errors: [] })); });
|
|
45
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { status: "compiling", statusLabel: state.status === "compiling" ? state.statusLabel : "", log: opts.retainLog ? state.log : "", duration: 0, errors: [] })); });
|
|
42
46
|
}
|
|
43
47
|
else if (data.code === "error") {
|
|
44
48
|
subject.update(function (state) { return (__assign(__assign({}, state), { status: "error", statusLabel: "", duration: 0, errors: data.errors })); });
|
|
45
49
|
}
|
|
46
50
|
else if (data.code === "finished") {
|
|
47
|
-
subject.update(function (state) { return (__assign(__assign({}, state), { status: data.watching ? "waiting" : "success", statusLabel: "", duration: data.duration, log: "", errors: data.errors })); });
|
|
51
|
+
subject.update(function (state) { return (__assign(__assign({}, state), { status: data.watching ? "waiting" : "success", statusLabel: "", duration: data.duration, log: opts.retainLog ? state.log : "", errors: data.errors })); });
|
|
48
52
|
}
|
|
49
53
|
else if (data.code === "invalidated") {
|
|
50
54
|
subject.update(function (state) { return (__assign(__assign({}, state), { status: "compiling", statusLabel: data.changedFile
|
|
51
55
|
? "Rebuilding (".concat(data.changedFile.replace(opts.baseDirectory, ""), ")")
|
|
52
|
-
: "Rebuilding (changes detected)", log: "", duration: 0, errors: [] })); });
|
|
56
|
+
: "Rebuilding (changes detected)", log: opts.retainLog ? state.log : "", duration: 0, errors: [] })); });
|
|
53
57
|
}
|
|
54
58
|
});
|
|
55
59
|
worker.on("exit", function () {
|
|
@@ -1,12 +1,3 @@
|
|
|
1
1
|
import { Configuration } from "webpack";
|
|
2
|
-
|
|
3
|
-
title: string;
|
|
4
|
-
baseDirectory: string;
|
|
5
|
-
themeName: string;
|
|
6
|
-
mode: "development" | "production";
|
|
7
|
-
target: "client" | "ssr";
|
|
8
|
-
isAdmin: boolean;
|
|
9
|
-
serverless: boolean;
|
|
10
|
-
hotPort?: number;
|
|
11
|
-
};
|
|
2
|
+
import { WebpackWorkerOptions } from "./state/compiler-state";
|
|
12
3
|
export default function getWebpackConfig(opts: WebpackWorkerOptions): Promise<Configuration>;
|
|
@@ -302,7 +302,7 @@ function getWebpackConfig(opts) {
|
|
|
302
302
|
var componentName = (0, change_case_1.pascalCase)(name);
|
|
303
303
|
return { relative: relative, name: name, module: module, componentName: componentName };
|
|
304
304
|
});
|
|
305
|
-
var useLoadableBlocks =
|
|
305
|
+
var useLoadableBlocks = false;
|
|
306
306
|
if (useLoadableBlocks) {
|
|
307
307
|
writeVirtualModule(ALIAS["@manifest/blocks"], "\n import coreBlocks from './blocks/_core.tsx'\n ".concat(!isServerless && "import loadable from '".concat(require.resolve("@loadable/component"), "';"), "\n\n export default {\n ...coreBlocks,\n ").concat(files
|
|
308
308
|
.map(function (_a) {
|
|
@@ -36,3 +36,14 @@ export declare type CompilerSignal = {
|
|
|
36
36
|
watching?: boolean;
|
|
37
37
|
errors?: CompilerError[];
|
|
38
38
|
};
|
|
39
|
+
export declare type WebpackWorkerOptions = {
|
|
40
|
+
title: string;
|
|
41
|
+
baseDirectory: string;
|
|
42
|
+
themeName: string;
|
|
43
|
+
mode: "development" | "production";
|
|
44
|
+
target: "client" | "ssr";
|
|
45
|
+
isAdmin: boolean;
|
|
46
|
+
serverless: boolean;
|
|
47
|
+
hotPort?: number;
|
|
48
|
+
retainLog?: boolean;
|
|
49
|
+
};
|
|
@@ -140,7 +140,7 @@ function beginWork(opts) {
|
|
|
140
140
|
var httpsAgent = new https_1.Agent({
|
|
141
141
|
rejectUnauthorized: false,
|
|
142
142
|
});
|
|
143
|
-
return (0, cross_fetch_1.default)(url, __assign(__assign({}, opts), { agent: httpsAgent }));
|
|
143
|
+
return (0, cross_fetch_1.default)(url, __assign(__assign({}, opts), { agent: url.includes("https") ? httpsAgent : undefined }));
|
|
144
144
|
},
|
|
145
145
|
})];
|
|
146
146
|
case 1:
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { WebpackWorkerOptions } from "../
|
|
1
|
+
import { WebpackWorkerOptions } from "../state/compiler-state";
|
|
2
2
|
export declare function beginWork(opts: WebpackWorkerOptions): Promise<void>;
|
|
@@ -53,6 +53,7 @@ var webpack_1 = __importDefault(require("webpack"));
|
|
|
53
53
|
var webpack_dev_server_1 = __importDefault(require("webpack-dev-server"));
|
|
54
54
|
var worker_threads_1 = require("worker_threads");
|
|
55
55
|
var get_webpack_config_1 = __importDefault(require("../get-webpack-config"));
|
|
56
|
+
var clean_1 = require("../clean");
|
|
56
57
|
var sendSignal = function (sig) {
|
|
57
58
|
if (worker_threads_1.parentPort) {
|
|
58
59
|
worker_threads_1.parentPort.postMessage(sig);
|
|
@@ -82,9 +83,12 @@ function beginWork(opts) {
|
|
|
82
83
|
sendSignal({
|
|
83
84
|
code: "compiling",
|
|
84
85
|
});
|
|
86
|
+
return [4 /*yield*/, (0, clean_1.cleanOutput)()];
|
|
87
|
+
case 1:
|
|
88
|
+
_b.sent();
|
|
85
89
|
_a = webpack_1.default;
|
|
86
90
|
return [4 /*yield*/, (0, get_webpack_config_1.default)(opts)];
|
|
87
|
-
case
|
|
91
|
+
case 2:
|
|
88
92
|
compiler = _a.apply(void 0, [_b.sent()]);
|
|
89
93
|
if (opts.hotPort) {
|
|
90
94
|
server = new webpack_dev_server_1.default(compiler, {
|
|
@@ -103,6 +107,7 @@ function beginWork(opts) {
|
|
|
103
107
|
contentBase: false,
|
|
104
108
|
noInfo: true,
|
|
105
109
|
https: false,
|
|
110
|
+
quiet: true,
|
|
106
111
|
// quiet: true,
|
|
107
112
|
// clientLogLevel: "silent",
|
|
108
113
|
headers: {
|
package/cli/build.dev.d.ts
CHANGED
package/cli/build.dev.js
CHANGED
|
@@ -50,40 +50,52 @@ var create_webpack_worker_1 = require("../build/create-webpack-worker");
|
|
|
50
50
|
var create_codegen_worker_1 = require("../build/create-codegen-worker");
|
|
51
51
|
function devCommand(opts) {
|
|
52
52
|
return __awaiter(this, void 0, void 0, function () {
|
|
53
|
-
var themeName, frontendObservable, adminObservable, codegenObservable;
|
|
53
|
+
var themeName, enableFrontend, enableAdmin, enableCodegen, frontendObservable, adminObservable, codegenObservable;
|
|
54
54
|
return __generator(this, function (_a) {
|
|
55
55
|
switch (_a.label) {
|
|
56
56
|
case 0: return [4 /*yield*/, (0, promptIfRepoNameIncorrect_1.promptIfRepoThemeMismatch)()];
|
|
57
57
|
case 1:
|
|
58
58
|
_a.sent();
|
|
59
59
|
themeName = path_1.default.basename(process.cwd());
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
60
|
+
enableFrontend = !opts.mode || opts.mode === "frontend";
|
|
61
|
+
enableAdmin = !opts.mode || opts.mode === "admin";
|
|
62
|
+
enableCodegen = !opts.mode || opts.mode === "codegen";
|
|
63
|
+
frontendObservable = enableFrontend
|
|
64
|
+
? (0, create_webpack_worker_1.createWebpackWorker)({
|
|
65
|
+
title: "Frontend Bundle",
|
|
66
|
+
baseDirectory: process.cwd() + "/",
|
|
67
|
+
mode: "development",
|
|
68
|
+
target: "client",
|
|
69
|
+
serverless: opts.serverless,
|
|
70
|
+
themeName: themeName,
|
|
71
|
+
isAdmin: false,
|
|
72
|
+
hotPort: 8991,
|
|
73
|
+
retainLog: opts.retainLog,
|
|
74
|
+
})
|
|
75
|
+
: undefined;
|
|
76
|
+
adminObservable = enableAdmin
|
|
77
|
+
? (0, create_webpack_worker_1.createWebpackWorker)({
|
|
78
|
+
title: "Admin Client",
|
|
79
|
+
baseDirectory: process.cwd() + "/",
|
|
80
|
+
mode: "development",
|
|
81
|
+
target: "client",
|
|
82
|
+
serverless: false,
|
|
83
|
+
themeName: themeName,
|
|
84
|
+
isAdmin: true,
|
|
85
|
+
hotPort: 8992,
|
|
86
|
+
retainLog: opts.retainLog,
|
|
87
|
+
})
|
|
88
|
+
: undefined;
|
|
89
|
+
codegenObservable = enableCodegen
|
|
90
|
+
? (0, create_codegen_worker_1.createCodegenWorker)({
|
|
91
|
+
baseDirectory: process.cwd() + "/",
|
|
92
|
+
watch: true,
|
|
93
|
+
retainLog: opts.retainLog,
|
|
94
|
+
})
|
|
95
|
+
: undefined;
|
|
84
96
|
// Set up a process which will regenerate schemas, and watch for changes
|
|
85
97
|
// Render output to screen
|
|
86
|
-
(0, ink_1.render)((0, jsx_runtime_1.jsx)(DevCLIDisplay_1.DevCLIDisplay, { bundles: [frontendObservable, adminObservable], codegen: codegenObservable }, void 0));
|
|
98
|
+
(0, ink_1.render)((0, jsx_runtime_1.jsx)(DevCLIDisplay_1.DevCLIDisplay, { bundles: [frontendObservable, adminObservable].filter(Boolean), codegen: codegenObservable }, void 0));
|
|
87
99
|
return [2 /*return*/];
|
|
88
100
|
}
|
|
89
101
|
});
|
package/cli/build.prod.js
CHANGED
|
@@ -44,6 +44,7 @@ var get_webpack_config_1 = __importDefault(require("../build/get-webpack-config"
|
|
|
44
44
|
var webpack_1 = require("webpack");
|
|
45
45
|
var promptIfRepoNameIncorrect_1 = require("../utils/promptIfRepoNameIncorrect");
|
|
46
46
|
var path_1 = __importDefault(require("path"));
|
|
47
|
+
var clean_1 = require("../build/clean");
|
|
47
48
|
function prodCommand(opts) {
|
|
48
49
|
return __awaiter(this, void 0, void 0, function () {
|
|
49
50
|
var contentBase, themeName, compiler, _a, _b;
|
|
@@ -55,6 +56,9 @@ function prodCommand(opts) {
|
|
|
55
56
|
case 1:
|
|
56
57
|
_c.sent();
|
|
57
58
|
themeName = path_1.default.basename(process.cwd());
|
|
59
|
+
return [4 /*yield*/, (0, clean_1.cleanOutput)()];
|
|
60
|
+
case 2:
|
|
61
|
+
_c.sent();
|
|
58
62
|
_a = webpack_1.webpack;
|
|
59
63
|
return [4 /*yield*/, (0, get_webpack_config_1.default)({
|
|
60
64
|
title: "Frontend Client",
|
|
@@ -65,7 +69,7 @@ function prodCommand(opts) {
|
|
|
65
69
|
themeName: themeName,
|
|
66
70
|
isAdmin: false,
|
|
67
71
|
})];
|
|
68
|
-
case
|
|
72
|
+
case 3:
|
|
69
73
|
_b = [
|
|
70
74
|
_c.sent()
|
|
71
75
|
];
|
|
@@ -78,7 +82,7 @@ function prodCommand(opts) {
|
|
|
78
82
|
themeName: themeName,
|
|
79
83
|
isAdmin: true,
|
|
80
84
|
})];
|
|
81
|
-
case
|
|
85
|
+
case 4:
|
|
82
86
|
compiler = _a.apply(void 0, [_b.concat([
|
|
83
87
|
_c.sent()
|
|
84
88
|
])]);
|
package/cli/cli.js
CHANGED
|
@@ -47,9 +47,13 @@ program
|
|
|
47
47
|
.command("dev")
|
|
48
48
|
.description("Build in dev mode")
|
|
49
49
|
.option("-s, --serverless", 'Build in "serverless" mode', false)
|
|
50
|
+
.option("-m, --mode <mode>", 'Defaults to all modes, but use "frontend", "admin" or "codegen" to run in just one mode', undefined)
|
|
51
|
+
.option("--verbose", "Enables log retention", false)
|
|
50
52
|
.action(function (options) {
|
|
51
53
|
(0, build_dev_1.devCommand)({
|
|
52
54
|
serverless: options.serverless,
|
|
55
|
+
mode: options.mode,
|
|
56
|
+
retainLog: options.verbose,
|
|
53
57
|
});
|
|
54
58
|
});
|
|
55
59
|
program
|
package/components/AdminBar.d.ts
CHANGED
package/entry/Root.d.ts
CHANGED
package/package.json
CHANGED