avo-hq/avo

Add a way to override JS controllers

オープン

#2,030 opened on 2023/11/14

 (1 件のコメント) (0 件のリアクション) (0 人の担当者)Ruby (308 件のフォーク)user submission
Help wantedHigh ImpactJavascriptStale exempt

Repository metrics

Stars
 (1,778 個のスター)
PR merge metrics
 (平均マージ 1d 6h) (30d で 67 merged PRs)

説明

Initial pseudo-code:

const registerController = (name, initialController, overridedController, application) => {
  const controller = overridedController || initialController
  application.register(name, controller)
}

// instead of 
application.register('action', ActionController)

registerController('action', ActionController, application)

It would be nice to be able to specify some conditionals.

  • if resource is user, use my version, if not, use default

コントリビューターガイド