NuxtN
Nuxt2y ago
1 reply
john

Is `corepack enable` required before calling `nypm i`?

Hi, I work for AWS Amplify, and we help customers deploy Nuxt apps by building this default build spec when we detect that Nuxt is being used:

version: 1
frontend:
  phases:
    preBuild:
      commands:
        - corepack enable
        - npx --yes nypm i
    build:
      commands:
        - npm run build
  artifacts:
    baseDirectory: .amplify-hosting
    files:
      - '**/*'


What I've observed is that builds appear to work as expected when the corepack enable command is omitted.

Are the any "gotchas" that would come from removing this line from our default build spec for new Amplify apps? I'd like to remove any extraneous commands from the default build spec.
Was this page helpful?