Skip to content

Fix dev taks exiting when linting fails #5474

Open
@romaricpascal

Description

@romaricpascal

What

Investigate why the dev Gulp tasks we run for development exits when linting fails.

Both govuk-frontend and the review app run linting on file changes, so we'll need to make sure linting errors in either no longer make Gulp exit.

The dev Gulp tasks can be run through either the following ways:

# Alias for `npm run dev`
npm start
# Runs both govuk-frontend and review app `dev` npm script in parallel
npm run dev
# Run the `dev` npm script of either workspace
npm run dev -w govuk-frontend
npm run dev -w @govuk-frontend/review
# Run `gulp` directly in either workspace
npx -w govuk-frontend gulp dev
npx -w @govuk-frontend/review gulp dev

Note

Fixing the issue should preserve the ability to disable linting, as this is useful to not clutter the output when building experimental/investigative code for spikes.

Why

This makes the dev process cumbersome, as the Gulp has to be re-launched every time a linting error happens during dev. While we want to fix these errors before commiting production code, we shouldn't have to go back in our terminal to re-launch the process because of a linting issue.

Who needs to work on this

Developers

Who needs to review this

Developers

Done when

  • Linting issues no longer make the dev task exit.

Metadata

Metadata

Assignees

No one assigned

    Labels

    small storytooling🐛 bugSomething isn't working the way it should (including incorrect wording in documentation)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions