@@ -34,7 +34,7 @@ import {
3434import { Schema as BrowserBuilderSchema } from '../browser/schema' ;
3535import { normalizeOptimization } from '../utils' ;
3636import { Schema } from './schema' ;
37- const opn = require ( 'opn ' ) ;
37+ const open = require ( 'open ' ) ;
3838
3939export type DevServerBuilderSchema = Schema & json . JsonObject ;
4040
@@ -83,7 +83,7 @@ export function serveWebpackBrowser(
8383 const browserTarget = targetFromTargetString ( options . browserTarget ) ;
8484 const root = context . workspaceRoot ;
8585 let first = true ;
86- let opnAddress : string ;
86+ let openAddress : string ;
8787 const host = new NodeJsSyncHost ( ) ;
8888
8989 const loggingFn = transforms . logging
@@ -202,18 +202,18 @@ export function serveWebpackBrowser(
202202 **
203203 ` ) ;
204204
205- opnAddress = serverAddress + webpackDevServerConfig . publicPath ;
205+ openAddress = serverAddress + webpackDevServerConfig . publicPath ;
206206 webpackConfig . devServer = webpackDevServerConfig ;
207207
208208 return runWebpackDevServer ( webpackConfig , context , { logging : loggingFn } ) ;
209209 } ) ,
210210 map ( buildEvent => {
211211 if ( first && options . open ) {
212212 first = false ;
213- opn ( opnAddress ) ;
213+ open ( openAddress ) ;
214214 }
215215
216- return { ...buildEvent , baseUrl : opnAddress } as DevServerBuilderOutput ;
216+ return { ...buildEvent , baseUrl : openAddress } as DevServerBuilderOutput ;
217217 } ) ,
218218 ) ;
219219}
0 commit comments