add support to Pretty diff beautifier
This commit is contained in:
parent
ee8c45becc
commit
3a6763a25c
|
@ -7,15 +7,25 @@
|
||||||
<script>
|
<script>
|
||||||
this.message = 'Hello, Riot!'
|
this.message = 'Hello, Riot!'
|
||||||
this.techs = [
|
this.techs = [
|
||||||
{ name: 'HTML' },
|
{
|
||||||
{ name: 'JavaScript' },
|
name: 'HTML'
|
||||||
{ name: 'CSS' }
|
}, {
|
||||||
|
name: 'JavaScript'
|
||||||
|
}, {
|
||||||
|
name: 'CSS'
|
||||||
|
}
|
||||||
]
|
]
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
:scope { font-size: 2rem }
|
:scope {
|
||||||
h3 { color: #444 }
|
font-size: 2rem;
|
||||||
ul { color: #999 }
|
}
|
||||||
|
h3 {
|
||||||
|
color: #444;
|
||||||
|
}
|
||||||
|
ul {
|
||||||
|
color: #999;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</sample>
|
</sample>
|
|
@ -54,6 +54,7 @@ module.exports = class PrettyDiff extends Beautifier
|
||||||
LESS: true
|
LESS: true
|
||||||
Swig: true
|
Swig: true
|
||||||
Visualforce: true
|
Visualforce: true
|
||||||
|
"Riot.js": true
|
||||||
}
|
}
|
||||||
|
|
||||||
beautify: (text, language, options) ->
|
beautify: (text, language, options) ->
|
||||||
|
@ -73,7 +74,7 @@ module.exports = class PrettyDiff extends Beautifier
|
||||||
lang = "ejs"
|
lang = "ejs"
|
||||||
when "ERB"
|
when "ERB"
|
||||||
lang = "html_ruby"
|
lang = "html_ruby"
|
||||||
when "Handlebars", "Mustache", "Spacebars", "Swig"
|
when "Handlebars", "Mustache", "Spacebars", "Swig", "Riot.js"
|
||||||
lang = "handlebars"
|
lang = "handlebars"
|
||||||
when "SGML"
|
when "SGML"
|
||||||
lang = "markup"
|
lang = "markup"
|
||||||
|
|
Loading…
Reference in New Issue