{"id":26636,"library":"wch-typescript","title":"Wch TypeScript Transpiler","description":"A TypeScript transpiler plugin for wchd (^0.10.0), version 0.1.3. Enables TypeScript compilation within the wch asset pipeline. No active maintenance noted; pinned to wch^0.10.0. Differentiator: lightweight alternative to full TS setup for wch projects.","status":"maintenance","version":"0.1.3","language":"javascript","source_language":"en","source_url":"https://github.com/aleclarson/wch-typescript","tags":["javascript"],"install":[{"cmd":"npm install wch-typescript","lang":"bash","label":"npm"},{"cmd":"yarn add wch-typescript","lang":"bash","label":"yarn"},{"cmd":"pnpm add wch-typescript","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency: required for wchd asset pipeline","package":"wch","optional":false}],"imports":[{"note":"CommonJS only; no ESM exports","symbol":"wchTypescript","correct":"const wchTypescript = require('wch-typescript')"},{"note":"Library exposes a default export; direct require gives function","wrong":"const wchTypescript = require('wch-typescript')","symbol":"default export","correct":"const wchTypescript = require('wch-typescript').default"},{"note":"Type-only import for TypeScript users","symbol":"TypeScript type","correct":"import type { Options } from 'wch-typescript'"}],"quickstart":{"code":"const wch = require('wch');\nconst wchTypescript = require('wch-typescript').default;\n\n// Configure wch pipeline\nwch.plugin(wchTypescript({\n  tsconfig: './tsconfig.json',\n  target: 'es2015',\n  sourcemap: false\n}));\n\n// Build pipeline\nwch.build('src/*.ts', 'dist/js/');","lang":"javascript","description":"Initializes wch-typescript plugin with options and runs a build from TypeScript source to JavaScript."},"warnings":[{"fix":"Ensure wch@^0.10.0 is installed.","message":"Requires wch version ^0.10.0; incompatible with other versions.","severity":"breaking","affected_versions":">=0.1.0 <0.2.0"},{"fix":"Check wch documentation for built-in TypeScript support.","message":"Package is in maintenance mode with no recent updates; consider migrating to official wch TypeScript support if available.","severity":"deprecated","affected_versions":"all"},{"fix":"Use require() instead of import.","message":"CommonJS only; no ES module support.","severity":"gotcha","affected_versions":"all"},{"fix":"Use .default or call the result directly.","message":"Default export is a function; direct require returns the function itself, not an object.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"npm install wch-typescript","cause":"Package not installed or not in node_modules.","error":"Error: Cannot find module 'wch-typescript'"},{"fix":"Ensure correct require: const wchTypescript = require('wch-typescript').default;","cause":"Wrong import pattern (e.g., used .default on a non-default export).","error":"TypeError: wchTypescript is not a function"},{"fix":"Use require('wch-typescript').default as the plugin.","cause":"Passing the module directly instead of the default export function.","error":"Error: Plugin must be a function"},{"fix":"npm install wch@^0.10.0","cause":"Peer dependency wch not installed.","error":"Error: Cannot find module 'wch'"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}