@types/static-eval
TypeScript icon, indicating that this package has built-in type declarations

0.2.34 • Public • Published

Installation

npm install --save @types/static-eval

Summary

This package contains type definitions for static-eval (https://github.com/substack/static-eval).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/static-eval.

index.d.ts

/// <reference types="esprima" />

import * as ESTree from "estree";

/**
 * Evaluates the given ESTree.Expression, with the given named variables in place.
 * @param ast [ESTree.Expression] An esprima expression derived from parse.body[].expression
 * @param vars Named variables, objects or functions which may be referenced in the expression.
 */
declare function evaluate(ast: ESTree.Expression, vars: { [name: string]: any }): any;
export = evaluate;

Additional Details

Credits

These definitions were written by Ben Liddicott.

Readme

Keywords

none

Package Sidebar

Install

npm i @types/static-eval

Weekly Downloads

4,042

Version

0.2.34

License

MIT

Unpacked Size

3.65 kB

Total Files

5

Last publish

Collaborators

  • types