MCPcopy Index your code
hub / github.com/react/create-react-app / start

Method start

test/fixtures/__shared__/util/scripts.js:30–57  ·  view source on GitHub ↗
({ smoke = false, env = {} } = {})

Source from the content-addressed store, hash-verified

28 }
29
30 async start({ smoke = false, env = {} } = {}) {
31 const port = await getPort();
32 const options = {
33 cwd: this.root,
34 env: Object.assign(
35 {},
36 {
37 CI: 'false',
38 FORCE_COLOR: '0',
39 BROWSER: 'none',
40 PORT: port,
41 },
42 env
43 ),
44 };
45
46 if (smoke) {
47 return await execaSafe('npm', ['start', '--smoke-test'], options);
48 }
49 const startProcess = execa('npm', ['start'], options);
50 await waitForLocalhost({ port });
51 return {
52 port,
53 done() {
54 startProcess.kill('SIGKILL');
55 },
56 };
57 }
58
59 async build({ env = {} } = {}) {
60 return await execaSafe('npm', ['run', 'build'], {

Callers 9

index.test.jsFile · 0.80
index.jsFile · 0.80
index.test.jsFile · 0.80
index.test.jsFile · 0.80
index.test.jsFile · 0.80
index.test.jsFile · 0.80
index.test.jsFile · 0.80
index.test.jsFile · 0.80
index.test.jsFile · 0.80

Calls 1

execaSafeFunction · 0.85

Tested by

no test coverage detected