Skip to content

Commit

Permalink
Wagtail 6.0 upgrade consideration: Deprecated WidgetWithScript base w…
Browse files Browse the repository at this point in the history
…idget class
  • Loading branch information
katdom13 committed Mar 1, 2024
1 parent cfc519a commit 5496215
Show file tree
Hide file tree
Showing 3 changed files with 327 additions and 152 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
// intance_selector/static/intance_selector/instance-selector-controller.js

class InstanceSelectorController extends window.StimulusModule.Controller {
static values = { config: Object };

connect() {
create_instance_selector_widget(this.configValue);
console.log(this.configValue);
}
}

window.wagtail.app.register('instance-selector', InstanceSelectorController);
Loading

0 comments on commit 5496215

Please sign in to comment.