<link rel="stylesheet" href="/_merged_assets/_static/search/noscript.css">
Apollo Elements Apollo Elements Guides API Blog Toggle darkmode

Generator: App

Generate an Apollo Elements skeleton app.

Example

npm init @apollo-elements -- \
  app \
    --uri '/graphql' \
    --install \
    --start \
    --overwrite
npm init @apollo-elements -- \
  app \
    --pkg-manager yarn \
    --uri '/graphql' \
    --install \
    --start \
    --overwrite
pnpm init @apollo-elements -- \
  app \
    --pkg-manager pnpm \
    --uri '/graphql' \
    --install \
    --start \
    --overwrite

Options

FlagDescriptionTypeDefault
--helpShow helpboolean
--versionShow version numberboolean
--pkg-managerPreferred package managernpm|yarn|pnpmnpm
--uri, -uURI to your GraphQL endpointstring
--overwriteOverwrite existing filesbooleanfalse
--codegenRun codegen after scaffolding filesstringtrue
--install, -iAutomatically install dependenciesbooleanfalse
--start, -sLaunch the dev server after scaffoldingbooleanfalse