{"id":21095427,"url":"https://github.com/faebeee/refactor","last_synced_at":"2026-02-25T14:07:33.193Z","repository":{"id":257646988,"uuid":"858886729","full_name":"faebeee/refactor","owner":"faebeee","description":null,"archived":false,"fork":false,"pushed_at":"2024-10-16T17:03:55.000Z","size":193,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-22T00:38:26.639Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/faebeee.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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-17T17:48:00.000Z","updated_at":"2024-12-13T23:03:05.000Z","dependencies_parsed_at":"2024-10-18T08:46:27.850Z","dependency_job_id":null,"html_url":"https://github.com/faebeee/refactor","commit_stats":null,"previous_names":["faebeee/refactor"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/faebeee%2Frefactor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/faebeee%2Frefactor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/faebeee%2Frefactor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/faebeee%2Frefactor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/faebeee","download_url":"https://codeload.github.com/faebeee/refactor/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254547132,"owners_count":22089267,"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-11-19T22:26:08.359Z","updated_at":"2025-10-24T19:46:42.634Z","avatar_url":"https://github.com/faebeee.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# refaktor\n\nThis is a tool to avoid errors during refactoring. It aims to create screenshots of given urls and you can compare them\nwith a later run to ensure that you don't break the UI while refactoring code.\n\n# installation\n\n```bash\nnpm install refaktor-cli -g\n```\n\n## Generate snapshots\n\nSetup you config file. [Example](https://github.com/faebeee/refactor/blob/v1.2.0/packages/refactor-cli/template/pages.js)\n\n__test.js__\n```javascript\nmodule.exports = [{\n  id: \"test\",\n  url: \"https://example.com\",\n  viewport: [1080, 1024],\n  output: \"./screenshots\",\n  pages: [\n    {\n      path: \"/\",\n      id: \"home\",\n    },\n      {\n      path: \"/hello-world\",\n      id: \"hello-world\",\n    },\n  ],\n}];\n```\n\n```bash\nrefaktor generate ./path-to-config.js\n```\n\n## Compare current state agains new taken screenshots\n\n```bash\nrefaktor compare ./path-to-config.js --ui\n```\n\n## Commands\n\n### generate\nGenerates the sources for later comparinson\n\n```bash\nrefaktor inspect ./out.json\n```\n\n### compare\nCompares screenshots and reports the result to the CLI\n\n```bash\nrefaktor compare ./test.js --cli\n```\n\n### inspect\nOpens up an UI for inspecting the result\n```bash\nrefaktor inspect ./out.json\n```\n### help\n\n```bash\nrefaktor help\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffaebeee%2Frefactor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffaebeee%2Frefactor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffaebeee%2Frefactor/lists"}