Skip to content

Commit 233338f

Browse files
Broccohansl
authored andcommitted
fix(@angular/cli): Correct service worker error message
Fixes #8490
1 parent b056b1d commit 233338f

File tree

1 file changed

+4
-4
lines changed
  • packages/@angular/cli/utilities/service-worker

1 file changed

+4
-4
lines changed

packages/@angular/cli/utilities/service-worker/index.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Filesystem } from '@angular/service-worker/config';
2-
import { stripIndent } from 'common-tags';
2+
import { oneLine } from 'common-tags';
33
import * as crypto from 'crypto';
44
import * as fs from 'fs';
55
import * as path from 'path';
@@ -71,9 +71,9 @@ export function augmentAppWithServiceWorker(projectRoot: string, appRoot: string
7171
const configPath = path.resolve(appRoot, 'ngsw-config.json');
7272

7373
if (!fs.existsSync(configPath)) {
74-
throw new Error(stripIndent`Expected to find an ngsw-config.json configuration file in the
75-
application root. Either provide one or disable Service Worker
76-
build support in angular-cli.json.`);
74+
throw new Error(oneLine`Error: Expected to find an ngsw-config.json configuration
75+
file in the ${appRoot} folder. Either provide one or disable Service Worker
76+
in .angular-cli.json.`);
7777
}
7878
const config = fs.readFileSync(configPath, 'utf8');
7979

0 commit comments

Comments
 (0)