{"id":13654443,"url":"https://github.com/leijing7/wx-mina-meteor","last_synced_at":"2025-04-23T09:33:30.533Z","repository":{"id":148498339,"uuid":"69986397","full_name":"leijing7/wx-mina-meteor","owner":"leijing7","description":"一个微信小程序通过 DDP 协议和 Meteor 后端交换数据的简单例子","archived":false,"fork":false,"pushed_at":"2017-08-08T07:08:43.000Z","size":2235,"stargazers_count":32,"open_issues_count":2,"forks_count":13,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-11-10T06:32:32.361Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/leijing7.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,"governance":null,"roadmap":null,"authors":null}},"created_at":"2016-10-04T16:57:46.000Z","updated_at":"2024-06-19T16:59:53.000Z","dependencies_parsed_at":"2023-05-20T08:15:24.840Z","dependency_job_id":null,"html_url":"https://github.com/leijing7/wx-mina-meteor","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/leijing7%2Fwx-mina-meteor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leijing7%2Fwx-mina-meteor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leijing7%2Fwx-mina-meteor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leijing7%2Fwx-mina-meteor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leijing7","download_url":"https://codeload.github.com/leijing7/wx-mina-meteor/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250407709,"owners_count":21425549,"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-08-02T03:00:32.621Z","updated_at":"2025-04-23T09:33:29.681Z","avatar_url":"https://github.com/leijing7.png","language":"JavaScript","funding_links":[],"categories":["Demo","Uncategorized"],"sub_categories":["Uncategorized"],"readme":"#### simple-todos-react\n是一个 meteor 的 React todo list 例子。我有一点改动，主要是在插入时需要用户登录改为了不用登录就可以添加新任务，这样小程序就可以添加新任务而不用登录。\n\n把 simple-todos-react/imports/api/tasks.js 里的 Meteor.methods 插入函数改为如下\n\n```\n'tasks.insert'(text) {\n  check(text, String);\n\n  // Make sure the user is logged in before inserting a task\n  // if (! this.userId) {\n  //   throw new Meteor.Error('not-authorized');\n  // }\n\n  const username = Meteor.users.findOne(this.userId) ? Meteor.users.findOne(this.userId).username : \"anonymous\"\n\n  Tasks.insert({\n    text,\n    createdAt: new Date(),\n    owner: this.userId,\n    username: username,\n  });\n},\n```\n\n这样才能在小程序端插入新的事项。\n\n#### webpacks\n是二次打包代码和已经打包好的\n\n#### wx\n是微信小程序代码\n\n\n![微信小程序 Reactive UI](https://github.com/leijing7/wx-mina-meteor/blob/master/static/mina.gif)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleijing7%2Fwx-mina-meteor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleijing7%2Fwx-mina-meteor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleijing7%2Fwx-mina-meteor/lists"}