[SOLVED] JADE anyone have a clue?

[SOLVED] JADE anyone have a clue?

extends layout

block content
  h1= title
  p The API is called by using #[a(href='/api/') https://img-abstraction-layer-jb-ps-bizzel.c9users.io/api/]
  p then adding a search term 

This is invalid apparently. I have no clue and can’t find any documentation.
An obvious choice for the default view engine :confused:

The error is The end of the string was reached with no closing bracket found.


Looks like you forgot the closing bracket for the link element:


So where does the link name text go?


This is the syntax I found:

a(href="#book-a") Book A

which would yield:

<a href="#book-a">Book A</a>

Hopefully it works? From: https://naltatis.github.io/jade-syntax-docs/


The syntax looks right. Are you sure the problem isn’t in the layout file?


Try adding a space between the final slash and the ending square bracket. If they’re too close, the precompiler may be interpreting this as an escape sequence.

#[a(href='/api/') https://img-abstraction-layer-jb-ps-bizzel.c9users.io/api/ ] // <-- extra space at the end

Also, Jade was renamed to Pug some time ago, so you’ll find more recent documentation at their new site.


Looks like the issue was the second link as the link name. I changed it to

#[a(href='https://github.com/JohnnyBizzel/img-abstraction-layer-jb-ps') GitHub Readme file]
Extra space is not important. :smiley: