Cosmetics
This commit is contained in:
parent
ee5dbcf33e
commit
e569bcb246
21 changed files with 54 additions and 65 deletions
|
|
@ -5,13 +5,10 @@ export default class extends Controller {
|
|||
static targets = ["input", "button"]
|
||||
|
||||
connect() {
|
||||
console.log("connect", this.inputTarget, this.buttonTarget)
|
||||
this.inputTarget.addEventListener("input", e => this.onUrlInputChange(e))
|
||||
}
|
||||
|
||||
onUrlInputChange(event) {
|
||||
console.log("connect", this.inputTarget, this.buttonTarget)
|
||||
console.log(event, this.buttonTarget)
|
||||
this.buttonTarget.href = this.inputTarget.value;
|
||||
this.buttonTarget.innerHTML = this.inputTarget.value;
|
||||
return true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue