We're using a particular jQuery plugin written in CoffeeScript at work and I'm hoping I can convert the project into somewhat normal looking JavaScript. The library looks like it's structured really well (good OOP practices), but I'd really like it if I could explore it's source code without having to learn all the tricks that CoffeeScript entails.

推荐答案

Compiling CoffeeScript into JavaScript usually results in JS that is fairly readable. You can convert snippets on the fly on the "Try CoffeeScript" tab of the CoffeeScript homepage, or via the CoffeeScript command line tool.

There are also tools like decaffeinate that convert CoffeeScript source to modern JavaScript.

If you know JavaScript and just want to be able to read the source of a file, a perusal of the CoffeeScript homepage will probably give you enough understanding of CoffeeScript to read CoffeeScript sources fairly easily.

Json相关问答推荐

如何形成正确的JQ表达式以从JSON文件中获得准确的输出数据?

JOLT转换以根据条件删除json对象

如何使用jq按键 Select 并获取整个json输出来更改json中的多个值

转换为Json时忽略内部对象中的数组

Jolt 变换 - 如何用字段值重命名字段?

在 PostgreSQL 中 Select 分层 JSON 作为表

判断 JSON 中的对象,而不是条件中提到的对象

从 Postgres 中的 json 对象中提取键、值

在 Bash 中访问 JSON 对象 - 关联数组/列表/另一个模型

Spring MVC 4:application/json内容类型设置不正确

Python - 如何将 JSON 文件转换为数据框

IE中Json响应下载(7~10)

在 JSON.stringify() 的输出中隐藏空值

Spring Security 和 JSON 身份验证

如何创建 JSON 对象 Node.js

Json.NET 是否缓存类型的序列化信息?

如何向(JSON)对象的原型添加方法?

为不同类型的项目数组正确的 JSON Schema

在 .NET 中缩小缩进的 JSON 字符串

从 JSON 到 JSONL 的 Python 转换