npm script to run coverage code example Example: npm run test:coverage command in jest npm test -- --coverage