indigoplugin.templates.CordovaTemplates.scala Maven / Gradle / Ivy
The newest version!
package indigoplugin.templates
object CordovaTemplates {
val packageFileTemplate: String =
s"""
{
"dependencies": {},
"cordova": {
"plugins": {
"cordova-plugin-whitelist": {}
},
"platforms": [
"ios",
"electron",
"browser"
]
},
"devDependencies": {
"cordova-browser": "^6.0.0",
"cordova-electron": "^1.1.1",
"cordova-ios": "^6.1.1",
"cordova-plugin-whitelist": "^1.3.4",
"whitelist": "^1.0.2"
}
}
"""
def configFileTemplate(title: String): String =
s"""
$title
$title
Your name
"""
def electronSettingsFileTemplate(windowWidth: Int, windowHeight: Int): String =
s"""
{
"browserWindow": {
"width": ${windowWidth.toString()},
"height": ${windowHeight.toString()},
"useContentSize": true,
"resizable": true,
"fullscreen": false,
"webPreferences": {
"nodeIntegration": false
}
}
}
"""
}