Change which category is displayed when the category dropdown is changed

on the analyze page.   Finishes #182277818
This commit is contained in:
Nelson Jovel 2022-05-27 21:39:44 -07:00
parent a04f797f30
commit 61978eb45d
8 changed files with 73 additions and 27 deletions

View file

@ -0,0 +1,9 @@
import { Controller } from "@hotwired/stimulus"
// Connects to data-controller="analyze"
export default class extends Controller {
connect() { }
change_category(event) {
window.location = event.target.value
}
}

View file

@ -2,4 +2,7 @@
// Run that command whenever you add a new controller or create them with
// ./bin/rails generate stimulus controllerName
import { application } from "./application";
import { application } from "./application"
import AnalyzeController from "./analyze_controller.js"
application.register("analyze", AnalyzeController)