Break out actions and payloads to their own files

The definitions take up a lot of space which makes it hard to see the dispatcher class, so break them out.
This commit is contained in:
Travis Ralston 2020-05-13 20:46:00 -06:00
parent 90a898d03f
commit 8c72c27da9
6 changed files with 87 additions and 52 deletions

23
src/dispatcher/actions.ts Normal file
View file

@ -0,0 +1,23 @@
/*
Copyright 2020 The Matrix.org Foundation C.I.C.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
// Dispatcher actions also extend into any arbitrary string, so support that.
export type DispatcherAction = Action | string;
export enum Action {
// TODO: Populate with actual actions
}