1

The official page(https://www.ninjaframework.org/documentation/modules.html) mentions Mustache template engine and its referenced page(https://github.com/kpacha/ninja-mustache) seems to say that Mustache template engine can be used. Is it true?

We added the following dependency to our pom.xml, but the Eclipse reported an error at the first line of this dependency in the pom.xml and we couldn't build our Ninja Web application.

<dependency>
    <groupId>org.ninjaframework</groupId>
    <artifactId>ninja-mustache-module</artifactId>
    <version>0.1.1</version>
</dependency>

If possible, what should we do to avoid the error and to use Mustache template engine instead of FreeMarker?

msnr-nks
  • 15
  • 5

1 Answers1

0

I have checked out the project and it seeems its Maven artifact is not published on any Maven artifactory, neither Maven Central Repository nor Github Maven registry.

The landing website https://kpacha.github.io/ninja-mustache/ contains links for downloading the project itself. The repository https://github.com/kpacha/ninja-mustache contains the following directories:

  • ninja-mustache-demo
  • ninja-mustache-module

The ninja-mustache-demo imports the ninja-mustache-module in the pom.xml and serves as an example. It assumes the ninja-mustache-module was packed and installed to the local Maven repository manually through the command mvn clean install.

The only way I see is to include ninja-mustache-module as a Maven module into your repository and add it as a dependency.

Nikolas Charalambidis
  • 40,893
  • 16
  • 117
  • 183
  • Thank you for your answer. I understood what you meant. I downloaded ninja-mustache-module, successfully did "mvn clean install" to my local repository and then the error on the Eclipse was erased and our project came to work!! But, Mustache template engine does not work, that is, {{ }}'s are not recognized. What is wrong? – msnr-nks Dec 15 '21 at 04:32
  • I think this is out of the scope of this question (I have no experience with these template engines so I am sorry, I have no idea how to help you here). Feel free to raise a new question and I suggest you mark either this answer as accepted to make this question resolved or wait for another one. (this is up to you). – Nikolas Charalambidis Dec 15 '21 at 09:52
  • 1
    Thank you for your suggestion. I will raise a new question. – msnr-nks Dec 16 '21 at 01:15