CtrlK
CommunityDocumentationLog inGet started
Tessl Logo

tessl/npm-coffeescript

tessl install tessl/npm-coffeescript@2.7.0

A programming language that compiles into JavaScript, offering more concise and readable syntax while maintaining full JavaScript compatibility.

Agent Success

Agent success rate when using this tile

77%

Improvement

Agent success rate improvement when using this tile compared to baseline

1.01x

Baseline

Agent success rate without this tile

76%

task.mdevals/scenario-7/

CoffeeScript Build Tool

A command-line utility that automates the compilation of CoffeeScript files using various build modes.

Capabilities

Compile single file to JavaScript

  • Given a CoffeeScript file at src/app.coffee, compiles it to dist/app.js using the compilation API @test
  • The compiled output includes proper JavaScript syntax without the top-level function wrapper @test

Compile multiple files from directory

  • Given a directory src/ containing multiple .coffee files, compiles all of them to a dist/ directory preserving the file structure @test
  • Skips non-CoffeeScript files (e.g., .js, .txt) during directory compilation @test

Print compiled output

  • Compiles a CoffeeScript file and returns the JavaScript output as a string without writing to disk @test

Implementation

@generates

API

/**
 * Compiles a single CoffeeScript file to JavaScript
 *
 * @param {string} inputPath - Path to the input .coffee file
 * @param {string} outputPath - Path to the output .js file
 * @param {object} options - Compilation options
 * @param {boolean} options.bare - Compile without top-level function wrapper (default: true)
 * @returns {Promise<void>}
 */
async function compileFile(inputPath, outputPath, options = {}) {
  // IMPLEMENTATION HERE
}

/**
 * Compiles all CoffeeScript files in a directory
 *
 * @param {string} inputDir - Path to the input directory
 * @param {string} outputDir - Path to the output directory
 * @param {object} options - Compilation options
 * @param {boolean} options.bare - Compile without top-level function wrapper (default: true)
 * @returns {Promise<number>} Number of files compiled
 */
async function compileDirectory(inputDir, outputDir, options = {}) {
  // IMPLEMENTATION HERE
}

/**
 * Compiles CoffeeScript source and returns JavaScript as string
 *
 * @param {string} filePath - Path to the .coffee file
 * @param {object} options - Compilation options
 * @param {boolean} options.bare - Compile without top-level function wrapper (default: true)
 * @returns {Promise<string>} Compiled JavaScript code
 */
async function printCompiled(filePath, options = {}) {
  // IMPLEMENTATION HERE
}

module.exports = {
  compileFile,
  compileDirectory,
  printCompiled
};

Dependencies { .dependencies }

coffeescript { .dependency }

Provides CoffeeScript compilation support.

@satisfied-by

Version

Workspace
tessl
Visibility
Public
Created
Last updated
Describes
npmpkg:npm/coffeescript@2.7.x
tile.json