Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save vinicioslc/e0b3b8ab308f1fb58d1ecfa2e827d2e8 to your computer and use it in GitHub Desktop.
Save vinicioslc/e0b3b8ab308f1fb58d1ecfa2e827d2e8 to your computer and use it in GitHub Desktop.
Fix maximum callstack size exceeds when use .npmrc

The simplest workaround its rename .npmrc before executes npm install and after install deps restore the original file, like the following approach:

    steps:
      - uses: actions/checkout@v2
      - name: Use Node.js ${{ matrix.node-version }}
        uses: actions/setup-node@v1
        with:
          node-version: ${{ matrix.node-version }}
      # move .npmrc to not cause  "Maximum call stack size exceeded" error when npm install executes
      - run: |
          mv -f .npmrc ./bak.npmrc
          npm install; mv -f bak.npmrc .npmrc; ls -al
          npm run build --if-present
          npm run test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment