🚨 Active Supply Chain Attack:node-ipc Package Compromised.Learn More
Socket
Book a DemoSign in
Socket

@bufbuild/empty-test-package

Package Overview
Dependencies
Maintainers
5
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

@bufbuild/empty-test-package

A CEL evaluator for ECMAScript

latest
Source
npmnpm
Version
0.4.0
Version published
Weekly downloads
0
Maintainers
5
Weekly downloads
 
Created
Source

@bufbuild/cel

This package provides a CEL evaluator for ECMAScript.

Example

Let's evaluate a CEL expression that has the variable name and uses the strings extension functions:

import { run } from "@bufbuild/cel";
import { strings } from "@bufbuild/cel/ext";

run(
  `name.indexOf('taco') == 0`, // CEL expression to run
  { name: "tacocat" }, // Bind a value to the variable `name`
  { funcs: strings }, // Register `indexOf` and other string extensions
); // true

That's it!

For an example of creating resusable evaluator and more, refer to example.ts.

Types

The table below maps JS types to CEL types.

  • Input column is any value that can be passed to the evaluator as input. (CelInput)
  • CEL Type column is the CEL type it will represent at runtime. (CelType)
  • Output column is the type of values that are returned by the evaluator, either as returned from eval or as arguments to function implementations. (CelValue)
Input (JS Type)CEL Type (runtime)Output (JS Type)
number, {Float,Double}Valuedoublenumber
bigint, all signed int wrappersintbigint
CelUint, all unsigned int wrappersuintCelUint
string, StringValuestringstring
Uint8Array, BytesValuebytesUint8Array
Map, ReflectMapmapCelMap
any[], ReflectListlistCelList
boolean, BoolValueboolboolean
nullnull_typenull
CelTypetypeCelType
Timestamp, ReflectMessagetimestampReflectMessage
Duration, ReflectMessagedurationReflectMessage
Message, ReflectMessage, Any<typeName>ReflectMessage
google.protobuf.Value and friendsdouble/bool/string/list/map/nullnumber/boolean/string/CelList/CelMap

Keywords

javascript

FAQs

Package last updated on 30 Apr 2026

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