Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/releases/october' into feat/add-…
Browse files Browse the repository at this point in the history
…refine-hr-minimal-example
  • Loading branch information
alicanerdurmaz committed Sep 26, 2024
2 parents e856b5a + 273bc2e commit fe6dade
Show file tree
Hide file tree
Showing 34 changed files with 1,472 additions and 259 deletions.
43 changes: 43 additions & 0 deletions .changeset/chilly-bottles-grab.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
"@refinedev/core": minor
---

feat: add [`<Link />`](https://refine.dev/docs/routing/components/link/) component to navigate to a resource with a specific action. Under the hood, It uses [`useGo`](https://refine.dev/docs/routing/hooks/use-go/) to generate the URL.

## Usage

```tsx
import { Link } from "@refinedev/core";

const MyComponent = () => {
return (
<>
{/* simple usage, navigates to `/posts` */}
<Link to="/posts">Posts</Link>
{/* complex usage with more control, navigates to `/posts` with query filters */}
<Link
go={{
query: {
// `useTable` or `useDataGrid` automatically use this filters to fetch data if `syncWithLocation` is true.
filters: [
{
operator: "eq",
value: "published",
field: "status",
},
],
},
to: {
resource: "posts",
action: "list",
},
}}
>
Posts
</Link>
</>
);
};
```

[Fixes #6329](https://github.com/refinedev/refine/issues/6329)
2 changes: 2 additions & 0 deletions .changeset/fifty-moons-flash.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,5 @@ export const Sider = () => {
return <div>{/* ... */}</div>;
};
```

[Fixes #6352](https://github.com/refinedev/refine/issues/6352)
9 changes: 9 additions & 0 deletions .changeset/itchy-moose-reflect.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@refinedev/core": minor
---

chore: From now on, [`useLink`](https://refine.dev/docs/routing/hooks/use-link/) returns [`<Link />`](https://refine.dev/docs/routing/components/link/) component instead of returning [`routerProvider.Link`](https://refine.dev/docs/routing/router-provider/#link).

Since the `<Link />` component uses `routerProvider.Link` under the hood with leveraging `useGo` hook to generate the URL there is no breaking change. It's recommended to use the `<Link />` component from the `@refinedev/core` package instead of `useLink` hook. This hook is used mostly for internal purposes and is only exposed for customization needs.

[Fixes #6329](https://github.com/refinedev/refine/issues/6329)
9 changes: 9 additions & 0 deletions .changeset/large-pots-smell.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@refinedev/devtools-server": patch
---

chore: bump express version to latest

Bump `express` dependecy to `^4.21.0` to fix vulnerability in `serve-static`.

[Resolves #6321](https://github.com/refinedev/refine/issues/6321)
9 changes: 9 additions & 0 deletions .changeset/mean-comics-live.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@refinedev/cli": patch
---

chore(cli): remove unused express dependency

Removed `express` dependency which triggers a vulnerability warning from `serve-static`.

[Resolves #6321](https://github.com/refinedev/refine/issues/6321)
Loading

0 comments on commit fe6dade

Please sign in to comment.