{"id":13687343,"url":"https://github.com/davestewart/alias-hq","last_synced_at":"2025-05-16T04:04:08.190Z","repository":{"id":41892074,"uuid":"289023663","full_name":"davestewart/alias-hq","owner":"davestewart","description":"The end-to-end solution for configuring, refactoring, maintaining and using path aliases","archived":false,"fork":false,"pushed_at":"2024-09-10T09:04:22.000Z","size":1925,"stargazers_count":335,"open_issues_count":20,"forks_count":14,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-05-13T19:21:41.227Z","etag":null,"topics":["aliases","configuration","jest","rollup","vscode","vue","webpack","webstorm"],"latest_commit_sha":null,"homepage":"https://davestewart.co.uk/projects/open-source/alias-hq/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/davestewart.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","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":"2020-08-20T14:11:31.000Z","updated_at":"2025-05-09T15:30:04.000Z","dependencies_parsed_at":"2023-11-09T22:32:59.102Z","dependency_job_id":"b302da8c-bcb6-40da-baa9-289d4de6d3ed","html_url":"https://github.com/davestewart/alias-hq","commit_stats":{"total_commits":151,"total_committers":8,"mean_commits":18.875,"dds":0.07284768211920534,"last_synced_commit":"7886b86ea191d2a9fec9fce5c0896dc732655d6d"},"previous_names":[],"tags_count":40,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davestewart%2Falias-hq","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davestewart%2Falias-hq/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davestewart%2Falias-hq/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davestewart%2Falias-hq/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/davestewart","download_url":"https://codeload.github.com/davestewart/alias-hq/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254464891,"owners_count":22075570,"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":["aliases","configuration","jest","rollup","vscode","vue","webpack","webstorm"],"created_at":"2024-08-02T15:00:52.839Z","updated_at":"2025-05-16T04:04:08.169Z","avatar_url":"https://github.com/davestewart.png","language":"JavaScript","funding_links":[],"categories":["Node Libraries","webpack","webstorm","JavaScript"],"sub_categories":[],"readme":"# Alias HQ \n\n![tests][tests]\n[![npm version][npm-version-src]][npm-version-href]\n[![npm downloads][npm-downloads-src]][npm-downloads-href]\n[![License][license-src]][license-href]\n\n\u003e The end-to-end solution for configuring, refactoring, maintaining and using path aliases\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/davestewart/alias-hq/master/docs/assets/logo.png\" alt=\"Alias HQ logo\"\u003e\n\u003c/p\u003e\n\n## Abstract\n\nPath \"aliases\" are special identifiers (starting with `@` or `~` ) that point to specific folders.\n\nUsing them in your codebase makes your imports easier to read and maintain:\n\n```js\n// from this\nimport { fooify } from '../../../core/services/foo' \n\n// to this\nimport { fooify } from '@services/foo' \n```\n\nThey are widely supported in the JavaScript ecosystem, *however*:\n\n- libraries have incompatible formats so require separate configurations  \n- maintaining duplicate configurations is fiddly and error-prone \n- migrating source code is laborious and long-winded\n\n## Overview\n\nAlias HQ is build-time tool which:\n\n- uses `ts/jsconfig.json` as the single source of configuration \n- provides one-liner integrations to popular bundlers, frameworks and libraries\n- has a CLI for quick configuration, and even source code migration\n\nBegin by [configuring](./docs/cli/paths.md) aliases in your project's `ts/jsconfig.json`:\n\n```json\n{\n  \"compilerOptions\": {\n    \"baseUrl\": \"src\",\n    \"paths\": {\n      \"@packages/*\": [ \"../packages/*\" ],\n      \"@/*\": [ \"/*\" ],\n      \"@app/*\": [ \"/app/*\" ],\n      \"@services/*\": [ \"/app/services/*\" ]\n    }\n  }\n}\n```\n\nUse the [API](./docs/api/api.md) to sync your toolchain, frameworks, even your IDE:\n\n```js\n// webpack.config.js\nconfig.resolve.alias = hq.get('webpack')\n\n// jest.config.js\nconfig.moduleNameMapper = hq.get('jest')\n\n// etc...\n```\nUse the [CLI](./docs/cli/cli.md) to migrate or maintain your source code:\n\n```\n? What do you want to do?\n  - Configure paths\n  - Setup integrations\n❯ - Update source code\n  - Help\n  - Exit\n```\n\nFor a list of all supported frameworks, see the [integrations](docs/integrations.md) doc.\n\n## Benefits\n\nIf you are *already* using aliases:\n\n- The Alias API **simplifies** your tooling with a single [config file](docs/cli/paths.md) and [one-liner integrations](docs/integrations.md)\n\nIf you are *thinking about* using aliases:\n\n- The Alias CLI **migrates** your project by [configuring your paths](docs/cli/paths.md) and [rewriting your imports](docs/cli/source.md) \n\nYou can **configure and migrate any project** in less than a minute by:\n\n- installing the package\n- running the CLI\n- following the prompts\n\n## Getting started\n\nInstall via your package manager of choice:\n\n```bash\nnpm i --save-dev alias-hq\n```\n\n```bash\nyarn add -D alias-hq\n```\n\nTo jump in without much reading:\n\n- [Quick start](docs/quick-start.md)\n\nFor step-by-step instructions:\n\n- [Documentation](docs/README.md)\n\nFor a short video:\n\n- [Click here](https://twitter.com/i/status/1298592287266611205)\n\nWanna support the project?\n\n- Tweet or [retweet](https://twitter.com/dave_stewart/status/1297906829868109825) about it :)\n\n\u003c!-- Badges --\u003e\n[npm-version-src]: https://img.shields.io/npm/v/alias-hq/latest.svg?style=flat\u0026colorA=18181B\u0026colorB=2EBCDC\n[npm-version-href]: https://npmjs.com/package/alias-hq\n\n[npm-downloads-src]: https://img.shields.io/npm/dm/alias-hq.svg?style=flat\u0026colorA=18181B\u0026colorB=6F6A92\n[npm-downloads-href]: https://npmjs.com/package/alias-hq\n\n[license-src]: https://img.shields.io/npm/l/alias-hq.svg?style=flat\u0026colorA=18181B\u0026colorB=B41C64\n[license-href]: https://npmjs.com/package/alias-hq\n\n[tests]: https://github.com/davestewart/alias-hq/workflows/tests/badge.svg\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavestewart%2Falias-hq","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdavestewart%2Falias-hq","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavestewart%2Falias-hq/lists"}