{"id":13491514,"url":"https://github.com/Utopiah/aframe-persist-component","last_synced_at":"2025-03-28T08:33:16.178Z","repository":{"id":57174245,"uuid":"79245679","full_name":"Utopiah/aframe-persist-component","owner":"Utopiah","description":"Persisting Aframe attribute data using localStorage","archived":false,"fork":false,"pushed_at":"2017-01-24T11:26:45.000Z","size":282,"stargazers_count":13,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-26T23:03:35.319Z","etag":null,"topics":["aframe","component","localstorage","virtual-reality","webvr"],"latest_commit_sha":null,"homepage":"http://vatelier.net/MyDemo/aframe-persist-component/","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/Utopiah.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":"2017-01-17T16:12:10.000Z","updated_at":"2024-11-15T20:33:36.000Z","dependencies_parsed_at":"2022-09-02T12:11:25.530Z","dependency_job_id":null,"html_url":"https://github.com/Utopiah/aframe-persist-component","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/Utopiah%2Faframe-persist-component","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Utopiah%2Faframe-persist-component/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Utopiah%2Faframe-persist-component/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Utopiah%2Faframe-persist-component/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Utopiah","download_url":"https://codeload.github.com/Utopiah/aframe-persist-component/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245996757,"owners_count":20707311,"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":["aframe","component","localstorage","virtual-reality","webvr"],"created_at":"2024-07-31T19:00:57.753Z","updated_at":"2025-03-28T08:33:15.755Z","avatar_url":"https://github.com/Utopiah.png","language":"JavaScript","funding_links":[],"categories":["Uncategorized"],"sub_categories":["Uncategorized"],"readme":"# aframe-persist-component\nUse localStorage to make data persist over experiences.\n\nTro try the example http://vatelier.net/MyDemo/aframe-persist-component/ move the camera around then refresh. You can also move the cube around using the inspector.\n\n![preview](https://utopiah.github.io/aframe-persist-component/preview.gif)\n\n## Properties\n\n| Property | Description                                                          | Default Value |\n| -------- | -------------------------------------------------------------------- | ------------- |\n|attribute | specify which attributes of an entity should be saved                | position      |\n|debug     | console.log() when attributes are loaded, saved and with what values | true          |\n\n## Installation\n\n### Browser\n\nInstall and use by directly including the component:\n```html\n  \u003cscript src=\"https://rawgit.com/Utopiah/aframe-persist-component/master/aframe-persist-component.js\"\u003e\u003c/script\u003e\n```\n## Basic usage\n```html\n  \u003ca-scene\u003e\n    \u003ca-camera id=\"mycamera\" persist\u003e\u003c/a-camera\u003e\n  \u003c/a-scene\u003e\n```\n## Example\n```html\n\u003chead\u003e\n  \u003ctitle\u003elocal state save\u003c/title\u003e\n  \u003cscript src=\"https://aframe.io/releases/0.4.0/aframe.min.js\"\u003e\u003c/script\u003e\n  \u003cscript src=\"https://rawgit.com/Utopiah/aframe-persist-component/master/aframe-persist-component.js\"\u003e\u003c/script\u003e\n\u003c/head\u003e\n\u003cbody\u003e\n  \u003ca-scene\u003e\n    \u003ca-camera id=\"testingid\" persist=\"debug:true;\"\n      persist__rot=\"debug:true; attribute:rotation;\"\u003e\u003c/a-camera\u003e\n    \u003ca-box id=\"testingid2\"\n      persist__pos=\"debug:true; attribute:position;\"\n      persist__rot=\"debug:true; attribute:rotation;\"\u003e\u003c/a-box\u003e\n    \u003c!-- commented out to remove shader errors...\n    \u003ca-box scale=\"20 20 20\" color=\"grey\" scale=\"1\" material=\"side:double\"\u003e\u003c/a-box\u003e\n--\u003e\n    \n  \u003c/a-scene\u003e\n\u003c/body\u003e\n```\n\n## Limitations\n- There is no traversal, each attribute to be saved has to be explicitely defined as such.\n- Each entity *requires* to have its unique ID, if not a warning message will de displayed then nothing will be saved.\n- Simple attributes like visible work but composed attributes (e.g. color or material) do not work.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FUtopiah%2Faframe-persist-component","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FUtopiah%2Faframe-persist-component","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FUtopiah%2Faframe-persist-component/lists"}