{"id":28736191,"url":"https://github.com/foxbenjaminfox/meteor-coffeescript","last_synced_at":"2025-06-16T01:06:00.648Z","repository":{"id":30826853,"uuid":"34384204","full_name":"foxbenjaminfox/meteor-coffeescript","owner":"foxbenjaminfox","description":"A community version of Meteor's coffeescript package.","archived":false,"fork":false,"pushed_at":"2022-06-05T23:16:31.000Z","size":15,"stargazers_count":7,"open_issues_count":3,"forks_count":5,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-03-21T03:50:25.528Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://atmospherejs.com/coffee/script","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/foxbenjaminfox.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-04-22T10:29:35.000Z","updated_at":"2024-03-21T03:50:25.529Z","dependencies_parsed_at":"2022-08-26T16:40:17.164Z","dependency_job_id":null,"html_url":"https://github.com/foxbenjaminfox/meteor-coffeescript","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/foxbenjaminfox/meteor-coffeescript","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxbenjaminfox%2Fmeteor-coffeescript","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxbenjaminfox%2Fmeteor-coffeescript/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxbenjaminfox%2Fmeteor-coffeescript/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxbenjaminfox%2Fmeteor-coffeescript/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/foxbenjaminfox","download_url":"https://codeload.github.com/foxbenjaminfox/meteor-coffeescript/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxbenjaminfox%2Fmeteor-coffeescript/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260079424,"owners_count":22955701,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-06-16T01:05:58.456Z","updated_at":"2025-06-16T01:06:00.607Z","avatar_url":"https://github.com/foxbenjaminfox.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# coffeescript\n\n[CoffeeScript](http://coffeescript.org/) is a little language that\ncompiles into JavaScript. It provides a simple syntax without lots of\nbraces and parentheses.  The code compiles one-to-one into the\nequivalent JS, and there is no interpretation at runtime.\n\nCoffeeScript is supported on both the client and the server. Files\nending with `.coffee`, `.litcoffee`, or `.coffee.md` are automatically\ncompiled to JavaScript.\n\nThis is a fork of the core Meteor `coffeescript` package. As the per the [Meteor wiki](https://github.com/meteor/meteor/wiki/Contributing-to-Meteor#adding-new-packages-to-meteor):\n\n\u003e For historical reasons, some packages that really ought to be in Atmosphere are currently in core, like `less` and `coffeescript`.\n\nThe goal of this fork is to fix this problem by moving the `coffeescript` package out of core, allowing the community to build on it without having to go through the Meteor release cycle.\n\n### Unwrapped helpers and events\n\nInspired by the `mquandalle:jade` package, `coffee:script` allows you to keep each template's events and helpers in their own files while avoiding boilerplate.\n\nJust as `mquandalle:jade` let's you [define your templates unwrapped](https://github.com/mquandalle/meteor-jade#unwrapped-templates) using `.tpl.jade` files, `coffee:script` lets you do the same with events and helpers in `.events.coffee` and `.helpers.coffee` files, respectively.\n\nWithout this feature, you'd have to wrap your template's helpers and events in `Template.\u003cname\u003e.events` or `Template.\u003cname\u003e.helpers` blocks, thus repeating yourself and adding needless boilerplate to your code. But using `coffee:script`, if you save your helpers object in a file called `\u003cname\u003e.helpers.coffee`, that bit of boilerplate will be handled for you. This allows you to follow the \"don't repeat yourself\" (DRY) philosophy in the same way you may have gotten used to while using `mquandalle:jade`.\n\n### Namespacing and CoffeeScript\n\nHere's how CoffeeScript works with Meteor's namespacing.\n\n* Per the usual CoffeeScript convention, CoffeeScript variables are\n  file-scoped by default (visible only in the `.coffee` file where\n  they are defined.)\n\n* When writing a package, CoffeeScript-defined variables can be\n  exported like any other variable (see [Writing\n  Packages](#writingpackages)). Exporting a variable pulls it up to\n  package scope, meaning that it will be visible to all of the code in\n  your app or package (both `.js` and `.coffee` files).\n\n* Package-scope variables declared in `.js` files are visible in any\n  `.coffee` files in the same app or project.\n\n* There is no way to make a package-scope variable from a `.coffee`\n  file other than exporting it. We couldn't figure out a way to make\n  this fit naturally inside the CoffeeScript language. If you want to\n  use package-scope variables with CoffeeScript, one way is to make a\n  short `.js` file that declares all of your package-scope\n  variables. They can then be read, mutated, and extended in `.coffee`\n  files.\n\n* If you want to share variables between `.coffee` files in the same\n  package, and don't want to separately declare them in a `.js` file,\n  we have an experimental feature that you may like. An object called\n  `share` is visible in CoffeeScript code and is shared across all\n  `.coffee` files in the same package. So, you can write `share.foo`\n  for a value that is shared between all CoffeeScript code in a\n  package, but doesn't escape that package.\n\nHeavy CoffeeScript users, please let us know how this arrangement\nworks for you, whether `share` is helpful for you, and anything else\nyou'd like to see changed.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoxbenjaminfox%2Fmeteor-coffeescript","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffoxbenjaminfox%2Fmeteor-coffeescript","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoxbenjaminfox%2Fmeteor-coffeescript/lists"}