Skip to content

Commit 928ce6d

Browse files
committed
refactor: migrate from nextui to heroui
1 parent 0621d66 commit 928ce6d

File tree

18 files changed

+262
-255
lines changed

18 files changed

+262
-255
lines changed

.npmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
public-hoist-pattern[]=*@nextui-org/*
1+
public-hoist-pattern[]=*@heroui/*

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
# Next.js 15 TypeScript Web3 EVM — Template
1818

1919
This development starter template is the ultimate solution to help you getting started on your project in no time, without the hassle of setting up and configuring your development environment from scratch each time you start working.
20-
This repository is ideal for web3 and dapp (decentralized application) developers who want to build modern, fast and reliable web3 applications with the latest cutting edge technologies such as **Next.js 15**, **React.js 19**, **TypeScript**, **Shadcn/ui**, **Next UI**, **TailwindCSS**, **RainbowKit**, **Viem**, **Wagmi** and much more!
20+
This repository is ideal for web3 and dapp (decentralized application) developers who want to build modern, fast and reliable web3 applications with the latest cutting edge technologies such as **Next.js 15**, **React.js 19**, **TypeScript**, **Shadcn/ui**, **HeroUI**, **TailwindCSS**, **RainbowKit**, **Viem**, **Wagmi** and much more!
2121

2222
---
2323

@@ -73,7 +73,7 @@ This repository comes 🔋 packed with:
7373
- **Next.js 15**;
7474
- **React.js 19**;
7575
- **Shadcn/ui**;
76-
- **Next UI**;
76+
- **HeroUI**;
7777
- **TailwindCSS**;
7878
- **SASS** & **SCSS**;
7979
- **RainbowKit**;

_config.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ const config = {
22
metadata: {
33
title: 'Next.js 15 TypeScript Web3 EVM — Template',
44
description:
5-
'Boilerplate template designed to quickly bootstrap a Next.js Decentralized App, dApp, Web3 App, Web App, SPA or website with Next.js 15, React.js 19, TypeScript, Shadcn/ui, Next UI, TailwindCSS, RainbowKit, View, Wagmi and much more in just 30 seconds.',
5+
'Boilerplate template designed to quickly bootstrap a Next.js Decentralized App, dApp, Web3 App, Web App, SPA or website with Next.js 15, React.js 19, TypeScript, Shadcn/ui, HeroUI, TailwindCSS, RainbowKit, View, Wagmi and much more in just 30 seconds.',
66
keywords:
7-
'dapp-template, dapp-boilerplate, web3-template, web3-boilerplate, next.js 15, next.js-15-template, next.js-15-boilerplate, react.js 19, react.js-19-template, react.js-19-boilerplate, typescript, shadcn, shadcn/ui, next-ui, tailwindcss, eslint, prettier, husky, commitlint, lint-staged'
7+
'dapp-template, dapp-boilerplate, web3-template, web3-boilerplate, next.js 15, next.js-15-template, next.js-15-boilerplate, react.js 19, react.js-19-template, react.js-19-boilerplate, typescript, shadcn, shadcn/ui, hero-ui, tailwindcss, eslint, prettier, husky, commitlint, lint-staged'
88
},
99
server: {
1010
host: 'localhost',

next.config.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
*/
99
import './src/env.js';
1010

11-
/** @type {import('next').NextConfig} */
11+
import type { NextConfig } from 'next';
12+
1213
const nextConfig = {
1314
reactStrictMode: true,
1415
eslint: {
@@ -18,6 +19,6 @@ const nextConfig = {
1819
config.externals.push('pino-pretty', 'lokijs', 'encoding');
1920
return config;
2021
}
21-
};
22+
} satisfies NextConfig;
2223

2324
export default nextConfig;

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@
2424
"test:ui": "playwright test --ui"
2525
},
2626
"dependencies": {
27-
"@nextui-org/button": "^2.2.9",
28-
"@nextui-org/skeleton": "^2.2.5",
29-
"@nextui-org/system": "^2.4.6",
30-
"@nextui-org/theme": "^2.4.5",
27+
"@heroui/button": "^2.2.9",
28+
"@heroui/skeleton": "^2.2.5",
29+
"@heroui/system": "^2.4.6",
30+
"@heroui/theme": "^2.4.5",
3131
"@radix-ui/react-dialog": "^1.1.5",
3232
"@radix-ui/react-dropdown-menu": "^2.1.5",
3333
"@radix-ui/react-slot": "^1.1.1",

pnpm-lock.yaml

Lines changed: 222 additions & 216 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/app.webmanifest

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"lang": "en-EN",
33
"name": "Next.js 15 TypeScript Web3 EVM — Template",
44
"short_name": "Next.js 15 TypeScript Web3 EVM — Template",
5-
"description": "Boilerplate template designed to quickly bootstrap a Next.js Decentralized App, dApp, Web3 App, Web App, SPA or website with Next.js 15, React.js 19, TypeScript, Shadcn/ui, Next UI, TailwindCSS, RainbowKit, View, Wagmi and much more in just 30 seconds.",
5+
"description": "Boilerplate template designed to quickly bootstrap a Next.js Decentralized App, dApp, Web3 App, Web App, SPA or website with Next.js 15, React.js 19, TypeScript, Shadcn/ui, HeroUI, TailwindCSS, RainbowKit, View, Wagmi and much more in just 30 seconds.",
66
"start_url": "/",
77
"display": "standalone",
88
"orientation": "portrait",

src/components/counter.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import React, { useState } from 'react';
44

5-
import { Button } from '@nextui-org/button';
5+
import { Button } from '@heroui/button';
66

77
import { Card, CardContent, CardHeader } from './ui/card';
88

src/components/navbar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React from 'react';
22

3-
import { Skeleton } from '@nextui-org/skeleton';
3+
import { Skeleton } from '@heroui/skeleton';
44
import dynamic from 'next/dynamic';
55

66
const ThemeToggle = dynamic(() => import('./ui/theme-toggle'), {

src/components/providers/hero-ui.tsx

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
'use client';
2+
3+
import React from 'react';
4+
5+
import type { PropsWithChildren } from 'react';
6+
7+
import { HeroUIProvider } from '@heroui/system';
8+
9+
type THeroUiProvider = PropsWithChildren;
10+
11+
export default function HeroUiProvider({ children }: THeroUiProvider) {
12+
return <HeroUIProvider>{children}</HeroUIProvider>;
13+
}

src/components/providers/next-ui.tsx

Lines changed: 0 additions & 13 deletions
This file was deleted.

src/components/providers/root.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,18 @@ import React from 'react';
22

33
import type { PropsWithChildren } from 'react';
44

5-
import NextUiProvider from './next-ui';
5+
import HeroUiProvider from './hero-ui';
66
import ThemeProvider from './theme';
77
import Web3Provider from './web3';
88

99
type TRootProvider = PropsWithChildren;
1010

1111
export default function RootProvider({ children }: TRootProvider) {
1212
return (
13-
<NextUiProvider>
13+
<HeroUiProvider>
1414
<ThemeProvider>
1515
<Web3Provider>{children}</Web3Provider>
1616
</ThemeProvider>
17-
</NextUiProvider>
17+
</HeroUiProvider>
1818
);
1919
}

src/components/switch-chain/chains-list.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import React from 'react';
44

55
import type { Chain } from 'viem';
66

7-
import { Button } from '@nextui-org/button';
7+
import { Button } from '@heroui/button';
88

99
type TChainsList = {
1010
title: string;

src/components/ui/theme-toggle.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import React, { useState } from 'react';
44

5-
import { Button } from '@nextui-org/button';
5+
import { Button } from '@heroui/button';
66
import { Laptop, MoonStar, Sun } from 'lucide-react';
77
import { useTheme } from 'next-themes';
88

src/components/wallet/dropdown/commons/dynamic-fallback.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import React from 'react';
22

33
import type { PropsWithChildren } from 'react';
44

5-
import { Skeleton } from '@nextui-org/skeleton';
5+
import { Skeleton } from '@heroui/skeleton';
66

77
import { cn } from '@/lib/utils';
88

src/components/wallet/dropdown/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React, { useMemo, useRef, useState } from 'react';
22

3-
import { Button } from '@nextui-org/button';
3+
import { Button } from '@heroui/button';
44
import dynamic from 'next/dynamic';
55
import { useAccount } from 'wagmi';
66

src/components/wallet/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import React from 'react';
66

77
import type { ComponentProps } from 'react';
88

9-
import { Button } from '@nextui-org/button';
9+
import { Button } from '@heroui/button';
1010
import { useConnectModal } from '@rainbow-me/rainbowkit';
1111
import { useAccount } from 'wagmi';
1212

tailwind.config.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33

44
import type { Config } from 'tailwindcss';
55

6-
import { nextui } from '@nextui-org/theme';
6+
import { heroui } from '@heroui/theme';
77

88
// based on shadcn's styles
9-
const nextUIStyleOverride = {
9+
const heroUIStyleOverride = {
1010
layout: {
1111
disabledOpacity: '0.5', // shadcn: 0.9
1212
radius: {
@@ -27,7 +27,7 @@ const config = {
2727
darkMode: ['class'],
2828
content: [
2929
'./src/**/*.{ts,tsx}',
30-
'./node_modules/@nextui-org/theme/dist/components/**/*.{js,ts,jsx,tsx}'
30+
'./node_modules/@heroui/theme/dist/components/**/*.{js,ts,jsx,tsx}'
3131
],
3232
theme: {
3333
container: {
@@ -94,7 +94,7 @@ const config = {
9494
}
9595
}
9696
},
97-
plugins: [nextui(nextUIStyleOverride), require('tailwindcss-animate')]
97+
plugins: [heroui(heroUIStyleOverride), require('tailwindcss-animate')]
9898
} satisfies Config;
9999

100100
export default config;

0 commit comments

Comments
 (0)