本文整理匯總了TypeScript中fluxx.Action函數的典型用法代碼示例。如果您正苦於以下問題:TypeScript Action函數的具體用法?TypeScript Action怎麽用?TypeScript Action使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了Action函數的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1:
import { Action } from 'fluxx'
import {Company} from "../../company/companyModel";
import {Show} from "../../show/showModel";
import {Play} from "../playModel";
export const initialize = Action<{company: Company, show: Show, play: Play, playsFromShow: Array<Play>}>("initialize")
示例2:
import { Action } from 'fluxx'
import {ShowWithDependencies} from "../showModel";
export const updateList = Action<Array<ShowWithDependencies>>("updateList")
示例3: Action
import { Action } from 'fluxx'
import {Company} from "../../company/companyModel";
import {Show} from "../showModel";
export const initialize = Action<{company: Company, show?: Show}>("initialize")
export const updateTitle = Action<string>("updateTitle")
export const updateAuthor = Action<string>("updateAuthor")
export const updateDirector = Action<string>("updateDirector")
export const updateContent = Action<string>("updateContent")
export const updateErrors = Action<Array<string>>("updateErrors")
export const closeErrors = Action("closeErrors")
export const success = Action("success")
示例4: Action
import { Action } from 'fluxx'
export const updatePassword = Action<string>("updatePassword")
export const updatePassword2 = Action<string>("updatePassword2")
export const updateErrors = Action<Array<string>>("updateErrors")
export const closeErrors = Action("closeErrors")
export const success = Action("success")
示例5:
import { Action } from 'fluxx'
import {Reservation} from "../reservationModel";
export const initialize = Action<string>("initialize")
export const reservationLoaded = Action<Array<Reservation>>("reservationLoaded")
示例6:
import { Action } from 'fluxx'
import {PageInformation} from "../pageModel";
export const initialize = Action<PageInformation>("initialize")
示例7: Action
import { Action } from 'fluxx'
import {Theater} from "../theaterModel";
export const initializeEmpty = Action("initializeEmpty")
export const initialize = Action<Theater>("initialize")
export const updateName = Action<string>("updateName")
export const updateAddress = Action<string>("updateAddress")
export const updateContent = Action<string>("updateContent")
export const addSeat = Action("addSeat")
export const removeSeat = Action<number>("removeSeat")
export const selectSeat = Action<number>("selectSeat")
export const updateSeatCode = Action<{index: number, value: string}>("updateSeatCode")
export const updateSeatX = Action<{index: number, value: number}>("updateSeatX")
export const updateSeatY = Action<{index: number, value: number}>("updateSeatY")
export const updateSeatWidth = Action<{index: number, value: number}>("updateSeatWidth")
export const updateSeatHeight = Action<{index: number, value: number}>("updateSeatHeight")
export const updateSeatType = Action<{index: number, value: string}>("updateSeatType")
示例8: Action
import { Action } from 'fluxx'
import {Theater} from "../../theater/theaterModel";
import {Company} from "../../company/companyModel";
import {Show} from "../../show/showModel";
import {Play} from "../playModel";
export const initialize = Action<{company: Company, show: Show, play?: Play, theaters: Array<Theater>}>("initialize")
export const updateTheater = Action<string>("updateTheater")
export const addDate = Action("addDate")
export const removeDate = Action<number>("removeDate")
export const updateDate = Action<{index: number, value: Date}>("updateDate")
export const updateReservationEndDate = Action<{index: number, value: Date}>("updateReservationEndDate")
export const addPrice = Action("addPrice")
export const removePrice = Action<number>("removePrice")
export const updatePriceName = Action<{index: number, value: string}>("updatePriceName")
export const updatePriceValue = Action<{index: number, value: number}>("updatePriceValue")
export const updatePriceCondition = Action<{index: number, value: string}>("updatePriceCondition")
export const updateErrors = Action<Array<string>>("updateErrors")
export const closeErrors = Action("closeErrors")
示例9: Action
import { Action } from 'fluxx'
import {UserSessionAuthorization} from "./sessionModel"
import {SessionUser} from "./sessionStore"
export const login = Action<UserSessionAuthorization>("login")
export const logout = Action("logout")
export const updateUser = Action<SessionUser>("updateUser")
示例10:
import { Action } from 'fluxx'
import {Company} from "../companyModel";
import {Show} from "../../show/showModel";
export const initialize = Action<{company: Company, shows: Array<Show>}>("initialize")