Skip to content

Instantly share code, notes, and snippets.

@cypressious
Created November 25, 2017 00:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cypressious/0c7b02107bc7edf508ba784e643ece74 to your computer and use it in GitHub Desktop.
Save cypressious/0c7b02107bc7edf508ba784e643ece74 to your computer and use it in GitHub Desktop.
const val SCRIPT_PATH = "/content_script/build/classes/kotlin/main/min"
fun main(args: Array<String>) {
Promise.all(arrayOf(
browser.tabs.executeScript(Script("$SCRIPT_PATH/kotlin.js")),
browser.tabs.executeScript(Script("$SCRIPT_PATH/content_script.js"))
))
.then({ listenForClicks() })
.catch(::reportExecuteScriptError)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment