New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@vanviegen/typestript

Package Overview
Dependencies
Maintainers
1
Versions
1
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

@vanviegen/typestript

Tiny (3kb gzipped), dependency-free library that converts (most) TypeScript to JavaScript in the browser.

latest
Source
npmnpm
Version
0.1.0
Version published
Maintainers
1
Created
Source

TypeStript

A tiny (3kb gzipped), dependency-free library that converts (most) TypeScript to JavaScript in the browser.

Features

TypeStript is a lightweight TypeScript transpiler designed for in-browser use. It's perfect for live code examples, demos, and educational purposes where you need to convert TypeScript to JavaScript on the fly.

  • Tiny footprint: Only 3kb gzipped
  • Zero dependencies: Works standalone in any browser
  • Simple API: Easy to integrate
  • Error recovery: Can continue transpilation even when encountering errors

Warning

Do not trust your production code with this! It takes some shortcuts, and I haven't looked at any standards documents to write this.

Usage

Auto-transpile from CDN

<script src="https://unpkg.com/typestript@latest/dist-min/browser.js"></script>
<script src="text/typescript">
  interface User {
    name: string;
    age: number;
  }
  
  function greet(user: User): string {
    return `Hello, ${user.name}!`;
  }
  greet({name: "Frank", age: 44});
</script>

API

npm install typestript
const { typestript } = require('typestript');

const jsCode = typestript(`
  interface User {
    name: string;
    age: number;
  }
  
  function greet(user: User): string {
    return 'Hello, ' + user.name + '!';
  }
  greet({name: "Frank", age: 44});
`);

console.log(jsCode);

CLI

npx typestript inputfile.ts --output outputfile.js --debug --recover

Everything after the input filename can be left out.

Keywords

typescript

FAQs

Package last updated on 17 Apr 2025

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