quasarframework/quasar · error

Failed to install @capacitor/splash-screen. Please do it man

Error message

Failed to install @capacitor/splash-screen. Please do it manually.

What it means

installCapacitorAssets also ensures @capacitor/splash-screen is present as a runtime dependency; when `pm.installPackage('@capacitor/splash-screen')` fails, this warning is emitted. Generation continues (it later returns true), but splash screen assets won't apply unless the plugin is installed.

Source

Thrown at icongenie/lib/mount/mount-capacitor.js:54

      return false
    }
  }

  if (
    !pkg.dependencies?.['@capacitor/splash-screen'] &&
    !pkg.devDependencies?.['@capacitor/splash-screen']
  ) {
    const pm = createInstance(srcCapacitorDir)
    if (typeof pm === 'string') {
      warn(pm)
      return false
    }

    const success = await pm.installPackage('@capacitor/splash-screen')

    if (!success) {
      warn()
      warn('Failed to install @capacitor/splash-screen. Please do it manually.')
    }
  }

  return true
}

export async function mountCapacitor() {
  const hasInstalled = await installCapacitorAssets()
  if (!hasInstalled) return

  const success = await spawnSync('npx', ['@capacitor/assets', 'generate'], {
    cwd: srcCapacitorDir
  })

  if (!success) {
    warn()
    warn('Failed to run @capacitor/assets. Please do it manually.')
    console.log(' -> /src-capacitor: $ npx @capacitor/assets generate\n')

View on GitHub (pinned to 4841521b5f)

Solutions

  1. Install manually: npm install @capacitor/splash-screen.
  2. Inspect the package manager output above the warning for the root failure and resolve it (proxy, ERESOLVE, disk space).
  3. Verify the plugin appears in package.json dependencies, then re-run the generation.

Example fix

# before: automatic install failed
# after
npm install @capacitor/splash-screen
icongenie generate -m capacitor
Defensive patterns

Strategy: validation

Validate before calling

const pkg = JSON.parse(fs.readFileSync('package.json', 'utf8'));
if (!pkg.dependencies?.['@capacitor/splash-screen']) {
  console.log('Pre-install: npm install @capacitor/splash-screen');
}

Prevention

When it happens

Trigger: Running icongenie for Capacitor when package.json lacks @capacitor/splash-screen and the package manager install fails (registry unreachable, version conflict, permissions).

Common situations: CI with restricted network access; mismatched Capacitor versions causing resolution failures; offline development machines.

Related errors


AI-assisted analysis of quasarframework/quasar@4841521b5f (2026-08-30). Data as JSON: /api/errors/c0602fd0a2d4c505. Report an issue: GitHub.