Answer the question
In order to leave comments, you need to log in
How optimal is it to use Pug for the entire .vue file?
For example:
template
p(align='right') Ура! Ни одного брекета или тега в файле
script(lang='coffee')
export default
props:
document:
type: Object
required: true
methods:
// ...
style(lang='sass')
p
color: green
lang='sass'
and'coffee'
Answer the question
In order to leave comments, you need to log in
If you like "Python style" so much, then you should remember that Pug is an HTML templating engine. There is also coffee for similar syntax in javascript and sass (or stylus) for CSS.
As far as I understand, js, html, css is used by default in templating and this cannot be changed. But I advise you not to worry and always specify lang="pug", lang="coffee", lang="sass". Since you are writing a project and you understand and know everything, but if another programmer gets into your code, he will first burst his eyes from what he saw, then his brains will burst, since there is no explanation on what syntax it was written at all.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question