Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions goldens/public-api/angular/build/index.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ export type ApplicationBuilderOptions = {
progress?: boolean;
scripts?: ScriptElement[];
security?: Security;
server?: string;
serviceWorker?: ServiceWorker_2;
server?: Serv;
serviceWorker?: Serv;
sourceMap?: SourceMapUnion;
ssr?: SsrUnion;
statsJson?: boolean;
Expand Down
8 changes: 5 additions & 3 deletions packages/angular/build/src/builders/application/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -259,10 +259,12 @@ export async function normalizeOptions(
: await getTailwindConfig(searchDirectories, workspaceRoot, context);

let serverEntryPoint: string | undefined;
if (options.server) {
if (typeof options.server === 'string') {
if (options.server === '') {
throw new Error('The "server" option cannot be an empty string.');
}

serverEntryPoint = path.join(workspaceRoot, options.server);
} else if (options.server === '') {
throw new Error('The "server" option cannot be an empty string.');
}

let prerenderOptions;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
"description": "The full path for the browser entry point to the application, relative to the current workspace."
},
"server": {
"type": "string",
"description": "The full path for the server entry point to the application, relative to the current workspace.",
"oneOf": [
{
Expand Down