@nx/angular
Version:
23 lines (22 loc) • 934 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.normalizeOptions = normalizeOptions;
const path_1 = require("path");
const devkit_1 = require("@nx/devkit");
function normalizeOptions(schema) {
schema.buildLibsFromSource ??= true;
process.env.NX_BUILD_LIBS_FROM_SOURCE = `${schema.buildLibsFromSource}`;
process.env.NX_BUILD_TARGET = `${schema.buildTarget}`;
return {
...schema,
devRemotes: schema.devRemotes ?? [],
host: schema.host ?? 'localhost',
port: schema.port ?? 4200,
liveReload: schema.liveReload ?? true,
open: schema.open ?? false,
ssl: schema.ssl ?? false,
verbose: schema.verbose ?? false,
sslCert: schema.sslCert ? (0, path_1.join)(devkit_1.workspaceRoot, schema.sslCert) : undefined,
sslKey: schema.sslKey ? (0, path_1.join)(devkit_1.workspaceRoot, schema.sslKey) : undefined,
};
}