Open kizu opened 11 years ago
+1
Can you do up a mockup input and output of what you're after. I don't use jade myself, so not that familiar with its requirements. Hopefully we can get someone who uses jade to pimp out this plugin some more :)
If I have a layout, say, default.jade
like this:
+foo
.foo.bar
block
Then I want to use it in about.html.jade
:
---
layout: default
---
+foo
baz
Right now there would be an error with undefined foo
mixin, so we'd like to have all variables and mixins from layouts to be available in documents/nested layouts.
Balupton, firstly read little about jade mixins: https://github.com/visionmedia/jade#a14
I say otherwise:
All mixins from documents/nested layouts should be available in layout, where you use:
@content (Eco) e t. c.
+1
Please do something, that's annoying problem
Please submit a pull request, or add a bounty to inspire someone else to submit a pull request.
+1
@darrrk you should use !=
instead of #{}
Is there any way to make the layouts and documents to be in one scope? So I could define Jade's mixins and variables in one layout file and then reuse them in the documents?
Right now I need to manually write the includes for my
mixins.jade
in every document and layout, and it's not fun.