Fast, zero-configuration Flow type annotation removal tool for JavaScript with CLI and programmatic APIs
84
A command-line tool that processes JavaScript files and removes Flow type annotations, converting Flow-typed code to standard JavaScript.
The tool should:
.js, .jsx) @testBuild a tool that processes all files in a directory, removing Flow type annotations. The tool must filter files by extension before processing.
Extension filtering requirements:
.js,.jsx,.mjs).js,.mjs,.cjs,.jsx,.flow,.es6@generates
/**
* Processes files in a directory, removing Flow type annotations.
* Filters files by extension before processing.
*
* @param {string} inputDir - Input directory path
* @param {string} outputDir - Output directory path
* @param {string} extensions - Comma-separated list of extensions (e.g., '.js,.jsx')
* @returns {Object} Processing results with counts of processed and skipped files
*/
function processDirectory(inputDir, outputDir, extensions) {
// IMPLEMENTATION HERE
}
module.exports = { processDirectory };Provides Flow type annotation removal functionality.
Install with Tessl CLI
npx tessl i tessl/npm-flow-remove-typesevals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10