Security News
Input Validation Vulnerabilities Dominate MITRE's 2024 CWE Top 25 List
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
@refinedev/mui
Advanced tools
refine is a React-based framework for building internal tools, rapidly. It ships with Ant Design System, an enterprise-level UI toolkit.
refine is a React-based framework for the rapid ✨ development of web applications. It eliminates repetitive tasks demanded by CRUD operations and provides industry standard solutions for critical parts like authentication, access control, routing, networking, state management, and i18n.
refine is headless by design, thereby offering unlimited styling and customization options.
Instead of being a limited set of pre-styled components, refine is a collection of helper hooks
, components
, and providers
. They are all decoupled from UI components and business logic, so that they never keep you from customizing your UI or coding your own flow.
refine seamlessly works with any custom design or UI framework that you favor. For convenience, it ships with ready-made integrations for Ant Design System, Material UI, Mantine, and Chakra UI.
refine shines on data-intensive⚡ applications like admin panels, dashboards and internal tools. Thanks to the built-in SSR support, refine can also power customer-facing applications like storefronts.
You can take a look at some live examples that can be built using refine from scratch:
👉 Refer to most popular real use case examples
👉 More refine powered different usage scenarios can be found here
⚙️ Zero-config, one-minute setup with a single CLI command
🔌 Connectors for 15+ backend services including REST API, GraphQL, NestJs CRUD, Airtable, Strapi, Strapi v4, Strapi GraphQL, Supabase, Hasura, Appwrite, Firebase, and Directus.
🌐 SSR support with Next.js or Remix
🔍 Auto-generated CRUD UIs from your API data structure
⚛ Perfect state management & mutations with React Query
🔀 Advanced routing with any router library of your choice
🔐 Providers for seamless authentication and access control flows
⚡ Out-of-the-box support for live / real-time applications
📄 Easy audit logs & document versioning
💬 Support for any i18n framework
💪 Future-proof, robust architecture
⌛️ Built-in CLI with time-saving features
✅ Full test coverage
The fastest way to get started with refine is by using the create refine-app
project starter tool.
Run the following command to create a new refine project configured with Material UI as the default UI framework:
npm create refine-app@latest -- --preset refine-mui
Once the setup is complete, navigate to the project folder and start your project with:
npm run dev
Your refine application will be accessible at http://localhost:3000:
Let's consume a public fake REST API
and add two resources (blog_posts, categories) to our project. Replace the contents of src/App.tsx
with the following code:
import { Refine } from "@refinedev/core";
import {
ErrorComponent,
RefineSnackbarProvider,
notificationProvider,
ThemedLayout,
RefineThemes,
} from "@refinedev/mui";
import { CssBaseline, GlobalStyles, ThemeProvider } from "@mui/material";
import routerBindings, {
NavigateToResource,
UnsavedChangesNotifier,
} from "@refinedev/react-router-v6";
import dataProvider from "@refinedev/simple-rest";
import { BrowserRouter, Routes, Route, Outlet } from "react-router-dom";
import { MuiInferencer } from "@refinedev/inferencer/mui";
const App: React.FC = () => {
return (
<ThemeProvider theme={RefineThemes.Blue}>
<CssBaseline />
<GlobalStyles styles={{ html: { WebkitFontSmoothing: "auto" } }} />
<RefineSnackbarProvider>
<BrowserRouter>
<Refine
routerProvider={routerBindings}
dataProvider={dataProvider(
"https://api.fake-rest.refine.dev",
)}
notificationProvider={notificationProvider}
resources={[
{
name: "blog_posts",
list: "/blog-posts",
show: "/blog-posts/show/:id",
create: "/blog-posts/create",
edit: "/blog-posts/edit/:id",
},
]}
options={{
syncWithLocation: true,
warnWhenUnsavedChanges: true,
}}
>
<Routes>
<Route
element={
<ThemedLayout>
<Outlet />
</ThemedLayout>
}
>
<Route
index
element={
<NavigateToResource resource="blog_posts" />
}
/>
<Route path="blog-posts">
<Route index element={<MuiInferencer />} />
<Route
path="show/:id"
element={<MuiInferencer />}
/>
<Route
path="edit/:id"
element={<MuiInferencer />}
/>
<Route
path="create"
element={<MuiInferencer />}
/>
</Route>
<Route path="*" element={<ErrorComponent />} />
</Route>
</Routes>
<UnsavedChangesNotifier />
</Refine>
</BrowserRouter>
</RefineSnackbarProvider>
</ThemeProvider>
);
};
export default App;
🚀 Thanks to refine Inferencer package, it guesses the configuration to use for the list
, show
, create
, and edit
pages based on the data fetched from the API and generates the pages automatically.
Now, you should see the output as a table populated with blog_posts
& category
data:
You can get the auto-generated pages codes by clicking the Show Code
button on each page. Afterward, simply pass the pages to the resources
array by replacing with the Inferencer components.
👉 Jump to Tutorial to continue your work and turn the example into a full-blown CRUD application.
👉 Visit Learn the Basics Page to get informed about the fundamental concepts.
👉 Read more on Advanced Tutorials for different usage scenarios.
👉 See the real-life Finefoods Demo project.
👉 Play with interactive Examples
👉 Refer to contribution docs for more information
If you have any doubts related to the project or want to discuss something, then join our Discord Server.
Licensed under the MIT License, Copyright © 2021-present Refinedev
FAQs
refine is a React-based framework for building internal tools, rapidly. It ships with Ant Design System, an enterprise-level UI toolkit.
We found that @refinedev/mui demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.