Questions tagged [jade4j]

jade4j's intention is to be able to process jade templates in Java without the need of a JavaScript environment, while being fully compatible with the original jade syntax.

jade4j's intention is to be able to process jade templates in Java without the need of a JavaScript environment, while being fully compatible with the original jade syntax (source).

52 questions
1
vote
1 answer

How to use Pug/Jade iterations to create multiple elements with different content?

I'm presently learning iterations in Pug/Jade. I'd like to use this tool going forward. In the code below, you basically have what's supposed to amount to a slider. In the first instance, the #{i} is supposed to return values 1-4 to each listed…
1
vote
1 answer

Inlining Javascript in Jade while maintaining indentation

Is there a way to inline Javascript code in Jade script tag while maintaining indentation? Removing indentation works but it makes code extremely difficult to read and modify. Another option is to put Javascript in separate files, but then we need…
missingfaktor
  • 90,905
  • 62
  • 285
  • 365
0
votes
0 answers

Can't load styles using pug4j template engine in spring boot

I try to load style from my resources folder (/resources/static/styles.css) but embedded tomcat answers 404. @Configuration @EnableWebMvc public class PugTemplateConfiguration { @Bean public SpringTemplateLoader templateLoader() { …
Mikhail
  • 1
  • 1
0
votes
1 answer

How te read Object in Jade Pug?

I have this JSON that I send to the PUG page from router.get with the name of prices [{"space2":{"actualPrice":"$ 99.990","oldPrice":"$ 129.990","id":11098071}},{"h20":{"actualPrice":"$ 69.990","oldPrice":"$…
0
votes
0 answers

Pug Image Link Won't Render

I am trying to render an image in pug that is hosted elsewhere on the web, not as a static asset in my project. I can navigate to it fine and pull it up in my browser, but when I load my webpage it gives me the error in the console Refused to load…
Matt
  • 478
  • 4
  • 14
0
votes
1 answer

unable to escape In pug lang

So i have some user defined HTML generated using QuillJS (wysiwyg editor). as far as display / editing the text inside the editor is concerened it is working fine, but when i try to show the same data on a page using !{var} on my pug page it shows…
Nishant S Vispute
  • 713
  • 1
  • 7
  • 21
0
votes
1 answer

How do you migrate agents using the Jade framework in Java?

Is there anyone who knows of a method to migrate agent between containers in Jade framework without using the doMove() function of the agent class?
0
votes
1 answer

Jade4J: No such file or directory

I try to implement Jade4J in my Java Spring app. Unfortunately it can't find the template files. JadeConfig.java @Configuration @EnableWebMvc public class JadeConfig { @Bean public SpringTemplateLoader templateLoader() { …
mannitou
  • 123
  • 1
  • 9
0
votes
2 answers

How to iterate over two or more JSONs objects that came from requests in a jade template?

I am facing a issue at getting results from a REST api requests that return JSON objects. How am I getting the results in jade template? if team each member in team[0].members .team-member h4= member.name How is the data format for…
0
votes
1 answer

How to set some words of a sentence bold / strong with pug?

I use pug as a templating engine. I'm able to load content on my page. Following some snippets of my code: server.js routing.get('/introduction', (req, resp) => { loadContent( function(err, content){ if(content){ …
listener
  • 47
  • 7
0
votes
1 answer

Pug js how span element left inside a tag

i wonder how i can span element put to left inside of a tag? my syntax now: a Settings span img(src=setting) it's rendering like: Settings i tried to make: a span …
user3348410
  • 2,733
  • 10
  • 51
  • 85
0
votes
0 answers

Hostname and IP Address of the current Server running the app in frontend

I would like to know how can I display the hostname of the current server running the app. The same application is running on different servers (production, development, local etc). The backend of our application is in Java8, frontend in Javascript…
Waleed Asif
  • 159
  • 3
  • 15
0
votes
2 answers

Configuring Jade4J as default template engine in Spring

I recently picked Spring framework for my university project on Java course, picked Jade4J for my template engine already put the dependancy in pom.xml and installed the package but when i'm calling the Jade4J.render("./index.jade", model); but I'm…
B0re
  • 239
  • 1
  • 8
0
votes
1 answer

how to add user's information in mongoose database?

i have a registration form in .jade format form(method='post', action='/users/register', enctype='multipart/form-data') .form-group label Name input.form-control(name='name', type='text', placeholder='Enter Name' required) …
0
votes
1 answer

html radio button are not clickable (The actual file is jade)

This would be more easier question but I am stuck on some small simple thing: My angular object is like this: $scope.questions = [ { questionText: "1. This is a test question#1", choices: [{ id: 1, text: "NO", …
Tom
  • 1