Show HN: NCL – New Configuration Language
github.com4 pointsby ezioamf2 comments
alert#update_available [ //Composition is separated from definition
btn#update,
btn#cancel
]
alert { //All alert elements are defined as alertTemplate
type: alertTemplate
}
btn { //All btn elements are define as button
type: button
}
alert#update_available { //Define the title and description for the alert with ID update_available
title: Get the latest tvOS version
description: Get the latest tvOS version
}
btn#update {
text: Update Now
}
btn#cancel {
text: Cancel
}
//We could override the settings like CSS
(@language = "pt_br") {
//If variable language is pt_br override the content with Brazilian Portuguese texts
btn#update {
text: Atualize Agora
}
btn#cancel {
text: Cancelar
}
}