StorylyView

@objc(StorylyView)
public final class StorylyView : UIView

This class is the main view of Storyly.

  • This property triggers StorylyView initialization

    Declaration

    Swift

    @objc
    public var storylyInit: StorylyInit { get set }
  • RootviewController of the StorylyView

    Declaration

    Swift

    @objc
    public weak var rootViewController: UIViewController?
  • Delegate of the StorylyView which will notify you when an event occurs in StorylyView.

    Declaration

    Swift

    @objc
    public weak var delegate: StorylyDelegate?
  • Delegate of the StorylyView which will notify you when an product related event occurs in StorylyView.

    Declaration

    Swift

    @objc
    public weak var productDelegate: StorylyProductDelegate?
  • This property will allow you to add ad view between stories

    Declaration

    Swift

    @objc
    public weak var storylyAdViewProvider: StorylyAdViewProvider?
  • Undocumented

    Declaration

    Swift

    override public func layoutSubviews()
  • Undocumented

    Declaration

    Swift

    override public var accessibilityLabel: String? { get set }
  • Undocumented

    Declaration

    Swift

    override public var accessibilityIdentifier: String? { get set }
  • Undocumented

    Declaration

    Swift

    override public func willMove(toWindow newWindow: UIWindow?)
  • This function allows you to refetch the data from network By default you do not need to use this function.

    Declaration

    Swift

    @objc
    public func refresh()
  • This function allows you to open a specific story using story group id and story id.

    Declaration

    Swift

    public func openStory(storyGroupId: String, storyId: String? = nil, play: PlayMode = .Default) -> Bool

    Parameters

    storyGroupId

    Story group id of the story to be opened

    storyId

    Story id of the story to be opened

    Return Value

    Success of the operation

  • This function allows you to open using deeplink uri.

    Declaration

    Swift

    @objc
    public func openStory(payload: URL) -> Bool

    Parameters

    payload

    Intent data which includes storyly as host

    Return Value

    Success of the operation

  • Undocumented

    Declaration

    Swift

    @objc
    public func resumeStory(animated: Bool, completion: (() -> Void)? = nil)
  • Undocumented

    Declaration

    Swift

    @objc
    public func pauseStory(animated: Bool, completion: (() -> Void)? = nil)
  • Undocumented

    Declaration

    Swift

    @objc
    public func closeStory(animated: Bool, completion: (() -> Void)? = nil)
  • This function allows you to hydrate your products

    Declaration

    Swift

    @objc
    public func hydrateProducts(products: [STRProductItem])

    Parameters

    products

    list of products to hydrate products

  • This function allows you to update your cart

    Declaration

    Swift

    @objc
    public func updateCart(cart: STRCart)

    Parameters

    cart

    A STRCart objects to update cart

  • This function allows you to open your custom external view

    Declaration

    Swift

    @objc
    public func showExternalActionView(externalActionView: UIView)

    Parameters

    externalActionView

    External view to show

  • This function dismisses your already open external view

    Declaration

    Swift

    @objc
    public func dismissExternalActionView()