image: node:lts-alpine stages: - install - lint - build install: stage: install script: - npm install --prefer-offline cache: key: files: - package.json paths: - node_modules lint: stage: lint needs: ["install"] script: - npm run lint cache: key: files: - package.json paths: - node_modules policy: pull build: stage: build needs: ["lint"] script: - npm run build artifacts: paths: - $CI_PROJECT_DIR/dist cache: key: files: - package.json paths: - node_modules policy: pull