{"id":14954618,"url":"https://github.com/meteor/madewith","last_synced_at":"2025-10-19T22:30:19.623Z","repository":{"id":3028043,"uuid":"4048093","full_name":"meteor/madewith","owner":"meteor","description":null,"archived":false,"fork":false,"pushed_at":"2013-08-03T01:27:27.000Z","size":176,"stargazers_count":55,"open_issues_count":1,"forks_count":10,"subscribers_count":17,"default_branch":"master","last_synced_at":"2025-01-28T23:44:14.604Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/meteor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-04-17T02:17:46.000Z","updated_at":"2021-12-23T09:06:07.000Z","dependencies_parsed_at":"2022-09-09T09:50:41.668Z","dependency_job_id":null,"html_url":"https://github.com/meteor/madewith","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meteor%2Fmadewith","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meteor%2Fmadewith/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meteor%2Fmadewith/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meteor%2Fmadewith/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/meteor","download_url":"https://codeload.github.com/meteor/madewith/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237221176,"owners_count":19274447,"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":"2024-09-24T13:04:30.597Z","updated_at":"2025-10-19T22:30:14.318Z","avatar_url":"https://github.com/meteor.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MadeWith: A gallery of Meteor apps\n\n## Interesting bits of code\n\n### Disabling default mutator methods (from [server/startup.js](https://github.com/meteor/madewith/blob/master/server/startup.js))\n\n```javascript\nMeteor.startup(function() {\n  _.each(['madewith_apps', 'madewith_comments'], function(collection) {\n    _.each(['insert', 'update', 'remove'], function(method) {\n      Meteor.default_server.method_handlers['/' + collection + '/' + method] = function() {};\n    });\n  });\n});\n```\n\n### Defining explicit mutator methods, with some sort of security for upvoting (from [common/methods.js](https://github.com/meteor/madewith/blob/avital/common/methods.js))\n\n```javascript\nMeteor.methods({\n  // ...\n\n  vote: function(hostname) {\n    // if the app doesn't already have a vote in this minute,\n    // increment vote_count and mark this minute in the votes array.\n\n    // minutes since epoch\n    var vote_ts = Math.floor((new Date()).getTime() / 1000 / 60);\n\n    if (Meteor.isClient) {\n      Apps.update({name: hostname},\n                  {$inc: {vote_count: 1}, $addToSet: {votes: vote_ts}});\n    } else {\n      Apps.update({name: hostname, votes: {$ne: vote_ts}},\n                  {$inc: {vote_count: 1}, $addToSet: {votes: vote_ts}});\n    }\n  },\n\n  // ...\n});\n```\n\n### Restricting the fields sent down to the client (from [common/data_model.js](https://github.com/meteor/madewith/blob/avital/common/data_model.js))\n\n```javascript\nif (Meteor.isServer) {\n  Meteor.publish(\"allApps\", function() {\n    return Apps.find({}, {fields: {pw_sha: 0, votes: 0}});\n  });\n\n  // ...\n}\n```\n\n### Calling Meteor methods from outside the app (from the [madewith badge smartpackage](https://github.com/meteor/meteor/blob/master/packages/madewith/madewith.js))\n\n```javascript\nTemplate.madewith.events({\n  'click .madewith_upvote': function(event) {\n    var app = apps.findOne();\n    if (app) {\n      server.call('vote', hostname);\n      // ...\n    }\n  }\n});\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmeteor%2Fmadewith","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmeteor%2Fmadewith","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmeteor%2Fmadewith/lists"}