Options
All
  • Public
  • Public/Protected
  • All
Menu

@josh_stern/mktemp

Index

Functions

dir

  • Create a temporary directory.

    example
    import {dir} from '@josh_stern/mktemp';
    const myDir = await dir();
    // ...
    await myDir.clean();
    

    Parameters

    Returns Promise<TempDir>

    A promise that resolves with a temp directory instance.

file

  • Create a temporary file.

    example
    import {file} from '@josh_stern/mktemp';
    const myFile = await file();
    await myFile.handle.write('Hello for a little while');
    await myFile.clean();
    

    Parameters

    Returns Promise<TempFile>

    A promise that resolves to a temporary file object.

Generated using TypeDoc