{"id":16961995,"url":"https://github.com/wangdahoo/map-state-vmodel","last_synced_at":"2025-08-17T18:11:50.616Z","repository":{"id":64162044,"uuid":"118014919","full_name":"wangdahoo/map-state-vmodel","owner":"wangdahoo","description":"mapState for v-model","archived":false,"fork":false,"pushed_at":"2019-04-01T07:34:44.000Z","size":91,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-01T11:20:11.127Z","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/wangdahoo.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":"2018-01-18T17:26:17.000Z","updated_at":"2022-12-03T15:34:42.000Z","dependencies_parsed_at":"2023-01-15T01:16:12.565Z","dependency_job_id":null,"html_url":"https://github.com/wangdahoo/map-state-vmodel","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/wangdahoo/map-state-vmodel","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangdahoo%2Fmap-state-vmodel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangdahoo%2Fmap-state-vmodel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangdahoo%2Fmap-state-vmodel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangdahoo%2Fmap-state-vmodel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wangdahoo","download_url":"https://codeload.github.com/wangdahoo/map-state-vmodel/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangdahoo%2Fmap-state-vmodel/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259374996,"owners_count":22847878,"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-10-13T23:04:54.986Z","updated_at":"2025-06-17T11:09:40.155Z","avatar_url":"https://github.com/wangdahoo.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# map-state-vmodel\n\u003e mapState for v-model\n\n### Install\n\n```bash\n$ npm i map-state-vmodel\n```\n\n### How to Use\n\n* in *.vue\n\n```vue\n\u003ctemplate\u003e\n  \u003cdiv\u003e\n    \u003cinput v-model=\"userName\" /\u003e\n  \u003c/div\u003e\n\u003c/template\u003e\n\u003cscript\u003e\nimport {mapStateVModel} from 'map-state-vmodel'\n\nexport default {\n  computed: {\n    ...mapStateVModel('user', [\n      'userName'\n    ])\n  }\n}\n\u003c/script\u003e\n```\n\n* in store file `user.js`\n\n```js\nimport {createSetters} from 'map-state-vmodel'\n\nconst state = {\n  userName: 'wangdahoo'\n}\n\nconst mutations = {\n  ...createSetters(state)\n}\n\nconst getters = {}\n\nconst actions = {}\n\nexport default {\n  namespaced: true,\n  state,\n  mutations,\n  getters,\n  actions\n}\n\n```\n\nThat's it.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwangdahoo%2Fmap-state-vmodel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwangdahoo%2Fmap-state-vmodel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwangdahoo%2Fmap-state-vmodel/lists"}