Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@types/string-template

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/string-template

TypeScript definitions for string-template

  • 1.0.6
  • ts4.5
  • ts4.6
  • ts4.7
  • ts4.8
  • ts4.9
  • ts5.0
  • ts5.1
  • ts5.2
  • ts5.3
  • ts5.4
  • ts5.5
  • ts5.6
  • ts5.7
  • ts5.8
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
29K
increased by3.5%
Maintainers
1
Weekly downloads
 
Created
Source

Installation

npm install --save @types/string-template

Summary

This package contains type definitions for string-template (https://www.npmjs.com/package/string-template).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/string-template.

index.d.ts

/**
 * NAMESPACE
 */
declare namespace StringTemplate {
    /**
     * Format
     */
    interface Format {
        // Format using an object hash with keys matching [0-9a-zA-Z]+
        (string: string, object: any): string;
        // Format using a number indexed array
        (string: string, array: any[]): string;
        // Format using optional arguments
        (string: string, ...array: any[]): string;
        // Escape {} pairs by using double {{}}
        (string: string): string;
    }

    /**
     * Compile
     */
    interface Compile {
        (string: string, inline?: boolean): Template;
    }

    interface Template {
        (object: any): string;
        (array: any[]): string;
        (...array: any[]): string;
    }
}

/**
 * MODULES
 */
declare module "string-template" {
    const format: StringTemplate.Format;
    export = format;
}

declare module "string-template/compile" {
    const comile: StringTemplate.Compile;
    export = comile;
}

Additional Details

  • Last updated: Mon, 20 Nov 2023 23:36:24 GMT
  • Dependencies: none

Credits

These definitions were written by TonyYang.

FAQs

Package last updated on 21 Nov 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc