Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
Let me give you an example of my use cases. If there is a project with a size of, for example, 10 or more pages (one of my last 50+ pages), and they have a header, footer and menus that are repeated. Imagine that you do all this with copy-paste, and then you need to add another item or the layout of the header will change ... Changing manually is hell. In nunchucks, you can have a header and a footer, and connect the menu as modules, if something has changed - edit only one file, it changes everywhere at once.
Option two, you need to check and show the layout for reliability, overflowing the container, for example, there is a table, you can manually copy paste 30 lines, but then the document will be large and scrolling will be inconvenient, plus your eyes will get tired, in addition, you may need some -to set your special classes for every 10th line, and then add a couple more lines, and the order of the table rows has changed, and manually change all classes. In nunchucks, it is possible to create an array, as in programming, and run a loop with conditions and other goodies, and now you can add a couple of lines without any problems, simply by adding the necessary values to the array.
You can also insert svg into html, while not visually clogging the code, as a result, you can manage svg as part of the document, and at the same time cleanliness and order in src files.
https://mozilla.github.io/nunjucks/ Here are the docs.
How can it help in front-end layout? I can not understand.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question