@ops-ai/remix-toggly-core
v1.9.0
Published
Core types and utilities for Toggly Remix SDK - shared between server and client packages
Readme
@ops-ai/remix-toggly-core
Core types and utilities for Toggly Remix SDK - shared between server and client packages
Install
npm install @ops-ai/remix-toggly-coreDocumentation
- docs.toggly.io
- SDK catalog: root README
Telemetry
Core exports usage/metrics batchers and an HTTPS client. Optional native gRPC lives on a separate subpath so edge-safe consumers never import Node gRPC:
import {
TelemetryRuntime,
resolveTelemetryEnableFlag,
} from '@ops-ai/remix-toggly-core'
import { createGrpcClients } from '@ops-ai/remix-toggly-core/telemetry/grpc'Set TOGGLY_DISABLE_TELEMETRY=1 to force telemetry off. Prefer
@ops-ai/remix-toggly-server for automatic wiring on Node.
Browser @ops-ai/remix-toggly-client does not send Usage/Metrics telemetry.
Entity context
isFeatureEnabled / gate helpers accept optional entity context. User identity (IdentityContext) is separate from page-entity context. Register mappers with registerContext locally — this client does not PUT entity schemas.
Entity gates fail closed without context. See Entity & page context.
registerContext('Order', (order) => ({
kind: 'Order',
key: String(order.id),
attributes: { Status: order.status },
}))License
MIT — see also the repository LICENSE.
Issues
Use the structured issue templates.
