Git Product home page Git Product logo

pug-en's People

Contributors

audreytoskin avatar forbeslindesay avatar hemanth avatar joliss avatar kylekatarnls avatar lionnatsu avatar noahbrenner avatar noraj avatar phoebec2 avatar pixelart7 avatar qm3ster avatar samuells avatar strugee avatar timothygu avatar zearin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

pug-en's Issues

pug.compileClient example code is wrong

The example in pug.compileClient is wrong:

var pug = require('pug');

// Compile a function
var fn = pug.compileClient('string of pug', options);

// Render the function
var html = fn(locals);
// => 'function template(locals) { return "<string>of pug</string>"; }'

pug.compileClient return a string. fn is not a callable function, except we eval it.

Plugin Docs

I would like to add the plugin docs, per pugjs/pug#3211. I didn't even know that the sub packages could have their own plugins, maybe the first comment in that issue is mistaken on that point. My plan is to document all usages of this function (and maybe others if I find them), and write a very minimal description of the arguments they take. If i can figure it out, also what they are supposed to do. I will try to add this as a top level right-hand-side menu item in strings.json.

Please give me some feedback on this plan before next month when i will plan on starting this process.

Thanks for maintaining a favorite nodejs module of mine.

Optimization/Best Practices

Is there any way we could get a page for optimizing pug projects? Any gotchas that we need to be aware of, or ways that we can make sure that our apps scale?

Does pug v2 append file extension?

https://github.com/pugjs/pug-en/blob/master/src/language/inheritance.md

In Pug v1, if no file extension is given, .pug is automatically appended to the path, but in Pug v2 this is behavior is deprecated.

https://github.com/pugjs/pug-en/blob/master/src/language/includes.md

In Pug v1, if no file extension is given, .pug is automatically appended to the file name, but in Pug v2 this is behavior is removed.

Are they behave differently? or is a typo?

(master is at efc8d8f, now)

How to contribute

The docs for Pug are very nice in showing the pug and html code side-by-side.

How can one contribute to improving the docs? The PRs with proposed changes and improvements appear to be ignored.

Search engine

It would be nice to have a search bar on the documentation.

Attribute interpolation: remove info about old syntax

When quickly scanning the docs, some (including me) can spot the old syntax in the docs (a(href="/#{url}") Link) which was removed in 2.0 and without reading the text around it (which says it was removed), they can go and use it.

I propose removing this information from this page of the docs, maybe with link "There used to be some other syntax, see migration guide for more information".
I think that the information about usage of template strings and other ways of attr interpolation should not be removed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.