0

When I created and ran it in intellij Idea the following was output from the console and yet node is well configured to use proxy as I initialized a react application a minute ago.

java.lang.RuntimeException: Unable to initialize Vaadin DevModeHandler Failed to determine 'npm.cmd' tool. Please install it either:

  • by following the https://nodejs.org/en/download/ guide to install it globally
  • or by running the frontend-maven-plugin goal to install it in this project: $ mvn com.github.eirslett:frontend-maven-plugin:1.7.6:install-node-and-npm -DnodeVersion="v10.16.0"
4
  • V14 and the Gradle plugin currently only work in compat mode (the bower based, old one). You have to wait for an update of the plugin to support the npm based approach.
    – cfrick
    Oct 2, 2019 at 9:56
  • 1
    @cfrick Please don't add answers as comments Oct 2, 2019 at 12:16
  • Sorry, but we "know" that time, will fix this, so it makes more sense(to me) to comment and let OP know instead of writing an answer, that needs either attention in the future or has a BBD.
    – cfrick
    Oct 3, 2019 at 10:29
  • Update: Vaadin Ltd announced in 2021 full support for Gradle, in addition to Maven. This applies at least to versions 20+ (and perhaps 14, I just don’t know). See this company blog post and this tutorial. Feb 14, 2022 at 5:57

3 Answers 3

3

There is now an official Spring Boot example here: https://github.com/vaadin/base-starter-spring-gradle . The example uses the official Vaadin Gradle Plugin which has been rewritten from scratch to mimic the Vaadin Maven plugin. No subscription and no payments are required.

Currently the plugin is in alpha state, but all the features are there and the plugin can now be tried out by early adopters.

A complete list of example projects (including non-Spring example projects) can be found here: https://github.com/vaadin/vaadin-gradle-plugin/issues/19

2

yo need the equivalent to front-end-maven-plugin for gradle try it:

// build.gradle
plugins {
    id 'org.siouan.frontend' version '1.1.0'
}

frontend {
    nodeVersion = '12.14.0'
}

After that you need compile the project with gradle build command.

Regards!

1

The DS Gradle Vaadin plugin (https://github.com/devsoap/gradle-vaadin-flow) provides support Vaadin 14 and NPM / Polymer 3 based builds.

Currently the Vaadin 14 support of the plugin is in beta testing, you can try it out by adding it to your project like so:

plugins {
    id 'com.devsoap.vaadin-flow' version '1.3.1'
}

Please note that the Vaadin 14 support currently requires a DS PRO subscription (which can be aquired from here).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.