Options
All
  • Public
  • Public/Protected
  • All
Menu

External module targets/base

This module defines the base target. Other targets extend it. It is an internal target and should not be used by consumers.

internal

Index

Type aliases

WatchTaskFunction

WatchTaskFunction: TaskFunction & () => FSWatcher

Functions

addTask

  • addTask(taker: Undertaker, displayName: string, task: TaskFunction): TaskFunction
  • Name a task function and register it to the provided Undertaker (or Gulp) instance.

    Parameters

    • taker: Undertaker
    • displayName: string
    • task: TaskFunction

    Returns TaskFunction

generateBaseTasks

  • Generates gulp tasks available for every target (base tasks).

    Parameters

    • taker: Undertaker

      Undertaker (or Gulp) registry used to generate tasks.

    • targetOptions: TargetBase

      Target configuration.

    Returns BaseTasks

getCopy

  • getCopy(taker: Undertaker, srcDir: Furi, targetDir: Furi, copyOptions: Iterable<CopyOptions>): [TaskFunction, TaskFunction]
  • Generate a copy task (and the corresponding watch task) for the copy operations described by copyOptions

    Parameters

    • taker: Undertaker

      Undertaker (or Gulp) instance used to define parallel tasks.

    • srcDir: Furi

      Base directory for source resolution.

    • targetDir: Furi

      Base directory for target (build) resolution.

    • copyOptions: Iterable<CopyOptions>

      Simple copy operations to apply for this copy task.

    Returns [TaskFunction, TaskFunction]

    A tuple with the task function and corresponding watch task function.

gulpBufferSrc

  • gulpBufferSrc(filename: string, data: Buffer): ReadableStream
  • Creates a Vinyl stream source from a Buffer.

    Parameters

    • filename: string
    • data: Buffer

    Returns ReadableStream

nameTask

  • nameTask<T>(name: string, task: T): T & { displayName: string }
  • Adds a display name to the supplied task function and returns the task function.

    Type parameters

    • T: TaskFunction

    Parameters

    • name: string

      The display name to set.

    • task: T

      The task function to name.

    Returns T & { displayName: string }

    The input task, with its displayName property set to name.

registerBaseTasks

  • Generates and registers gulp tasks available for every target (base tasks).

    Parameters

    • taker: Undertaker

      Undertaker (or Gulp) instance where the tasks will be registered.

    • targetOptions: TargetBase

      Target configuration.

    Returns BaseTasks

resolveTargetBase

Generated using TypeDoc