{"id":14978355,"url":"https://github.com/bradgarropy/next-link","last_synced_at":"2025-08-08T05:10:44.893Z","repository":{"id":93265948,"uuid":"379305982","full_name":"bradgarropy/next-link","owner":"bradgarropy","description":"🔗 link component for next","archived":false,"fork":false,"pushed_at":"2023-03-01T04:42:21.000Z","size":1162,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-28T04:18:23.035Z","etag":null,"topics":["eslint","jest","link","next","prettier","react","typescript"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/@bradgarropy/next-link","language":"TypeScript","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/bradgarropy.png","metadata":{"files":{"readme":"readme.md","changelog":null,"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":"2021-06-22T14:51:43.000Z","updated_at":"2023-03-09T02:08:21.000Z","dependencies_parsed_at":"2023-04-03T09:59:23.634Z","dependency_job_id":null,"html_url":"https://github.com/bradgarropy/next-link","commit_stats":{"total_commits":14,"total_committers":2,"mean_commits":7.0,"dds":0.2142857142857143,"last_synced_commit":"1492562ce1e40412c1402992c8d5fc577ddd39fe"},"previous_names":[],"tags_count":7,"template":false,"template_full_name":"bradgarropy/react-library-starter","purl":"pkg:github/bradgarropy/next-link","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradgarropy%2Fnext-link","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradgarropy%2Fnext-link/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradgarropy%2Fnext-link/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradgarropy%2Fnext-link/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bradgarropy","download_url":"https://codeload.github.com/bradgarropy/next-link/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bradgarropy%2Fnext-link/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269366853,"owners_count":24405250,"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","status":"online","status_checked_at":"2025-08-08T02:00:09.200Z","response_time":72,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["eslint","jest","link","next","prettier","react","typescript"],"created_at":"2024-09-24T13:57:28.107Z","updated_at":"2025-08-08T05:10:44.852Z","avatar_url":"https://github.com/bradgarropy.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🔗 next link\n\n[![version][version-badge]][npm]\n[![downloads][downloads-badge]][npm]\n[![size][size-badge]][bundlephobia]\n[![github actions][github-actions-badge]][github-actions]\n[![coverage][codecov-badge]][codecov]\n[![typescript][typescript-badge]][typescript]\n[![contributing][contributing-badge]][contributing]\n[![contributors][contributors-badge]][contributors]\n[![discord][discord-badge]][discord]\n\n_🔗 link component for [`next`][next]_\n\n[Next][next] provides a [`\u003cLink\u003e`][link] component for routing between internal pages. For external links, you have to use a regular `\u003ca\u003e` tag. This `next-link` package solves that issue by providing a `\u003cLink\u003e` component that handles both internal and external urls.\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://www.npmjs.com/package/@bradgarropy/next-link\"\u003e\n        \u003cimg alt=\"next link\" src=\"./images/github.png\" width=\"500\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n## 📦 Installation\n\nThis package is hosted on [`npm`][npm].\n\n```bash\nnpm install @bradgarropy/next-link\n```\n\n## 🥑 Usage\n\nFor both internal and external links, use the `Link` component and pass it a `to` prop.\n\n```jsx\nimport Link from \"@bradgarropy/next-link\"\n\nconst App = () =\u003e {\n    return \u003cLink to=\"https://bradgarropy.com\"\u003ewebsite\u003c/Link\u003e\n}\n```\n\n## 📖 API Reference\n\n### `\u003cLink\u003e`\n\n| Name | Required | Default | Example                                    | Description               |\n| :--- | :------: | :-----: | :----------------------------------------- | :------------------------ |\n| `to` |  `true`  |         | `\"/home\"` \u003cbr\u003e `\"https://bradgarropy.com\"` | Internal or external url. |\n\nThe component also passes through all other `props`, like `className` or `passHref`. See the [`next/link`][link] documentation for other relevant props. The examples below cover some common uses.\n\n```jsx\n// internal link\n\u003cLink to=\"/home\"\u003ehome\u003c/Link\u003e\n\n// internal link with additional props\n\u003cLink to=\"/home\" className=\"nav-link\"\u003ehome\u003c/Link\u003e\n\n// external link\n\u003cLink to=\"https://bradgarropy.com\"\u003ewebsite\u003c/Link\u003e\n\n// external link with additional props\n\u003cLink to=\"https://bradgarropy.com\" className=\"nav-link\"\u003ewebsite\u003c/Link\u003e\n```\n\n## ❔ Questions\n\n🐛 report bugs by filing [issues][issues]  \n📢 provide feedback with [issues][issues] or on [twitter][twitter]  \n🙋🏼‍♂️ use my [ama][ama] or [twitter][twitter] to ask any other questions\n\n## ✨ contributors\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --\u003e\n\u003c!-- prettier-ignore-start --\u003e\n\u003c!-- markdownlint-disable --\u003e\n\u003ctable\u003e\n  \u003ctr\u003e\n    \u003ctd align=\"center\"\u003e\u003ca href=\"https://bradgarropy.com\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/11336745?v=4?s=100\" width=\"100px;\" alt=\"\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eBrad Garropy\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/bradgarropy/next-link/commits?author=bradgarropy\" title=\"Code\"\u003e💻\u003c/a\u003e \u003ca href=\"https://github.com/bradgarropy/next-link/commits?author=bradgarropy\" title=\"Documentation\"\u003e📖\u003c/a\u003e \u003ca href=\"https://github.com/bradgarropy/next-link/commits?author=bradgarropy\" title=\"Tests\"\u003e⚠️\u003c/a\u003e \u003ca href=\"#infra-bradgarropy\" title=\"Infrastructure (Hosting, Build-Tools, etc)\"\u003e🚇\u003c/a\u003e\u003c/td\u003e\n  \u003c/tr\u003e\n\u003c/table\u003e\n\n\u003c!-- markdownlint-restore --\u003e\n\u003c!-- prettier-ignore-end --\u003e\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n\n[codecov]: https://app.codecov.io/gh/bradgarropy/next-link\n[contributing]: https://github.com/bradgarropy/next-link/blob/master/contributing.md\n[contributors]: #-contributors\n[npm]: https://www.npmjs.com/package/@bradgarropy/next-link\n[codecov-badge]: https://img.shields.io/codecov/c/github/bradgarropy/next-link?style=flat-square\n[version-badge]: https://img.shields.io/npm/v/@bradgarropy/next-link.svg?style=flat-square\n[downloads-badge]: https://img.shields.io/npm/dt/@bradgarropy/next-link?style=flat-square\n[contributing-badge]: https://img.shields.io/badge/PRs-welcome-success?style=flat-square\n[contributors-badge]: https://img.shields.io/github/all-contributors/bradgarropy/next-link?style=flat-square\n[issues]: https://github.com/bradgarropy/next-link/issues\n[twitter]: https://twitter.com/bradgarropy\n[ama]: https://bradgarropy.com/ama\n[bundlephobia]: https://bundlephobia.com/result?p=@bradgarropy/next-link\n[size-badge]: https://img.shields.io/bundlephobia/minzip/@bradgarropy/next-link?style=flat-square\n[github-actions]: https://github.com/bradgarropy/next-link/actions\n[github-actions-badge]: https://img.shields.io/github/workflow/status/bradgarropy/next-link/%F0%9F%9A%80%20release?style=flat-square\n[typescript]: https://www.typescriptlang.org/dt/search?search=%40bradgarropy%2Fnext-link\n[typescript-badge]: https://img.shields.io/npm/types/@bradgarropy/next-link?style=flat-square\n[discord]: https://bradgarropy.com/discord\n[discord-badge]: https://img.shields.io/discord/748196643140010015?style=flat-square\n[next]: https://nextjs.org\n[link]: https://nextjs.org/docs/api-reference/next/link\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbradgarropy%2Fnext-link","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbradgarropy%2Fnext-link","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbradgarropy%2Fnext-link/lists"}