MCPcopy Index your code
hub / github.com/edc/mapcat

github.com/edc/mapcat @v0.2.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.2.0 ↗ · + Follow
11 symbols 22 edges 4 files 1 documented · 9%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

mapcat is a simple utility that concatenates JavaScript files while also consolidating the corresponding source map files. It is useful if you use compile-to-JS languages whose compiler emits source map files. This is the case for CoffeeScript "transpiler" version 1.6 or later.

It's very easy to use:

bin/mapcat input1.map input2.map -m output.map -j output.js

You specify the input by specifying the associated source map files - mapcat will find the actual JavaScript source files. Use -m to specify one output source map file and -j to specify one output JavaScript file. Invoke without any argument to see the (short) full help.

Example

There is a simple example project in the example folder. Run bash build.sh to build the project. Then open index.html with Webkit Nightly or Chrome with Source Map support turned on in the Developer Tools. If you have Scripts panel enabled, refresh the page and you will see the program pause at a predefined debugger line, and you are looking at, CoffeeScript!

WebKit Source Map support shows in developer tools

API

You can also use the simple API. It exposes one simple function:

var cat = require('mapcat').cat;
cat(['input1.map', 'input2.map'], 'output.js', 'out.map');

Core symbols most depended-on inside this repo

hasProp
called by 8
example/almond.js
normalize
called by 4
example/almond.js
callDep
called by 4
example/almond.js
makeRequire
called by 2
example/almond.js
splitPrefix
called by 2
example/almond.js
makeNormalize
called by 1
example/almond.js
makeLoad
called by 1
example/almond.js
makeConfig
called by 1
example/almond.js

Shape

Function 11

Languages

TypeScript100%

Modules by API surface

example/almond.js8 symbols
test/run-tests.js3 symbols

For agents

$ claude mcp add mapcat \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact