Skip to content

Commit

Permalink
[DeAngular][visualization][vislib] remove angular from vislib (#2138) (
Browse files Browse the repository at this point in the history
…#2270)

* remove angular import and $scope from Binder class since there is
no usage in the code

Issue resolved:
#2137

Signed-off-by: Anan Zhuang <ananzh@amazon.com>

Signed-off-by: Anan Zhuang <ananzh@amazon.com>
(cherry picked from commit 730a75a)

Co-authored-by: Anan Zhuang <ananzh@amazon.com>
  • Loading branch information
opensearch-trigger-bot[bot] and ananzh authored Sep 6, 2022
1 parent 71c7374 commit b6ab762
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions src/plugins/vis_type_vislib/public/vislib/lib/binder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@

import d3 from 'd3';
import $ from 'jquery';
import { IScope } from 'angular';

export interface Emitter {
on: (...args: any[]) => void;
Expand All @@ -42,13 +41,6 @@ export interface Emitter {
export class Binder {
private disposal: Array<() => void> = [];

constructor($scope: IScope) {
// support auto-binding to $scope objects
if ($scope) {
$scope.$on('$destroy', () => this.destroy());
}
}

public on(emitter: Emitter, ...args: any[]) {
const on = emitter.on || emitter.addListener;
const off = emitter.off || emitter.removeListener;
Expand Down

0 comments on commit b6ab762

Please sign in to comment.