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

@leaningtech/ts2cpp

Package Overview
Dependencies
Maintainers
3
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@leaningtech/ts2cpp

TypeScript declaration to C++ header transpiler for Cheerp

  • 1.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4
Maintainers
3
Weekly downloads
 
Created
Source

ts2cpp banner

A tool to generate C++ headers from typescript declaration files (.d.ts) for use with Cheerp.

Usage: ts2cpp [options]

Options:
  --pretty                 format output files
  --default-lib            generate headers for the default library
  --out, -o <file>         path to output file
  --ignore-errors          ignore errors
  --list-files             write a list of all included .d.ts files
  --verbose, -v            verbose output
  --verbose-progress       verbose progress
  --namespace <namespace>  wrap output in a namespace
  --no-constraints         do not use std::enable_if or static_asserts
  --full-names             always use fully qualified names
  -h, --help               display help for command

Setup

git clone https://github.com/leaningtech/ts2cpp.git
cd ts2cpp
npm i && npx tsc

Or run with npx:

npx @leaningtech/ts2cpp --help

Examples

Generating clientlib headers

mkdir -p cheerp
npx ts2cpp --default-lib --pretty

Generating headers from a custom declaration file

npx ts2cpp --pretty test.d.ts -o test.h

Keywords

FAQs

Package last updated on 15 Mar 2024

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