Class CleanFrontendMojo

java.lang.Object
org.apache.maven.plugin.AbstractMojo
com.vaadin.flow.plugin.maven.FlowModeAbstractMojo
com.vaadin.flow.plugin.maven.CleanFrontendMojo
All Implemented Interfaces:
com.vaadin.flow.plugin.base.PluginAdapterBase, org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
Direct Known Subclasses:
FrontendDanceMojo

@Mojo(name="clean-frontend", defaultPhase=PRE_CLEAN) public class CleanFrontendMojo extends FlowModeAbstractMojo
Goal that cleans the frontend files to a clean state.

Deletes Vaadin dependencies from package.json, the generated frontend folder and the npm/pnpm-related files and folders:

  • node_modules
  • pnpm-lock.yaml
  • package-lock.json
Since:
9.0
  • Constructor Details

    • CleanFrontendMojo

      public CleanFrontendMojo()
  • Method Details

    • executeInternal

      protected void executeInternal() throws org.apache.maven.plugin.MojoFailureException
      Description copied from class: FlowModeAbstractMojo
      Perform whatever build-process behavior this Mojo implements.
      This is the main trigger for the Mojo inside the Maven system, and allows the Mojo to communicate errors.
      Specified by:
      executeInternal in class FlowModeAbstractMojo
      Throws:
      org.apache.maven.plugin.MojoFailureException - if an expected problem (such as a compilation failure) occurs. Throwing this exception causes a "BUILD FAILURE" message to be displayed.