diff --git a/README.md b/README.md index a6e693d..ece14bd 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# @phphe/react-base-virtual-list ![GitHub License](https://img.shields.io/github/license/phphe/react-base-virtual-list) ![NPM Version](https://img.shields.io/npm/v/@phphe/react-base-virtual-list) ![GitHub Actions Workflow Status](https://img.shields.io/github/actions/workflow/status/phphe/react-base-virtual-list/build.yml) ![npm bundle size](https://img.shields.io/bundlephobia/minzip/%40phphe%2Freact-base-virtual-list) +# react-base-virtual-list ![GitHub License](https://img.shields.io/github/license/phphe/react-base-virtual-list) ![NPM Version](https://img.shields.io/npm/v/react-base-virtual-list) ![GitHub Actions Workflow Status](https://img.shields.io/github/actions/workflow/status/phphe/react-base-virtual-list/build.yml) ![npm bundle size](https://img.shields.io/bundlephobia/minzip/react-base-virtual-list) [中文](README_CN.md) @@ -13,15 +13,15 @@ React basic virtual list, supports common features and is easy to customize. [On ## Installation -- npm: `npm install @phphe/react-base-virtual-list` -- yarn: `yarn add @phphe/react-base-virtual-list` -- pnpm: `pnpm add @phphe/react-base-virtual-list` +- npm: `npm install react-base-virtual-list` +- yarn: `yarn add react-base-virtual-list` +- pnpm: `pnpm add react-base-virtual-list` - CDN: Check [iife](#iife). ## Usage ```tsx -import { VirtualList } from "@phphe/react-base-virtual-list"; +import { VirtualList } from "react-base-virtual-list"; export default function BaseExample() { const exampleData = [ @@ -90,7 +90,7 @@ First, use `ref` to obtain the exposed object. ```tsx import { useRef } from "react"; -import { VirtualList, VirtualListHandle } from "@phphe/react-base-virtual-list"; +import { VirtualList, VirtualListHandle } from "react-base-virtual-list"; export default function BaseExample() { const ref = useRef(null); @@ -135,8 +135,8 @@ You can host it on your server and then use the `script` tag to include it. Befo You can also use the following third-party CDN url to include it. -- unpkg: https://unpkg.com/@phphe/react-base-virtual-list -- jsdelivr: https://cdn.jsdelivr.net/npm/@phphe/react-base-virtual-list +- unpkg: https://unpkg.com/react-base-virtual-list +- jsdelivr: https://cdn.jsdelivr.net/npm/react-base-virtual-list ## Development diff --git a/README_CN.md b/README_CN.md index 3e8b093..f9a3ed2 100644 --- a/README_CN.md +++ b/README_CN.md @@ -1,4 +1,4 @@ -# @phphe/react-base-virtual-list ![GitHub License](https://img.shields.io/github/license/phphe/react-base-virtual-list) ![NPM Version](https://img.shields.io/npm/v/@phphe/react-base-virtual-list) ![GitHub Actions Workflow Status](https://img.shields.io/github/actions/workflow/status/phphe/react-base-virtual-list/build.yml) ![npm bundle size](https://img.shields.io/bundlephobia/minzip/%40phphe%2Freact-base-virtual-list) +# react-base-virtual-list ![GitHub License](https://img.shields.io/github/license/phphe/react-base-virtual-list) ![NPM Version](https://img.shields.io/npm/v/react-base-virtual-list) ![GitHub Actions Workflow Status](https://img.shields.io/github/actions/workflow/status/phphe/react-base-virtual-list/build.yml) ![npm bundle size](https://img.shields.io/bundlephobia/minzip/%40phphe%2Freact-base-virtual-list) [English](README.md) @@ -13,15 +13,15 @@ React 基础虚拟列表,实现了常用功能并且易于二次开发。[在 ## 安装 -- npm: `npm install @phphe/react-base-virtual-list` -- yarn: `yarn add @phphe/react-base-virtual-list` -- pnpm: `pnpm add @phphe/react-base-virtual-list` +- npm: `npm install react-base-virtual-list` +- yarn: `yarn add react-base-virtual-list` +- pnpm: `pnpm add react-base-virtual-list` - CDN: 见 [iife](#iife). ## 使用 ```tsx -import { VirtualList } from "@phphe/react-base-virtual-list"; +import { VirtualList } from "react-base-virtual-list"; export default function BaseExample() { const exampleData = [ @@ -90,7 +90,7 @@ export default function BaseExample() { ```tsx import { useRef } from "react"; -import { VirtualList, VirtualListHandle } from "@phphe/react-base-virtual-list"; +import { VirtualList, VirtualListHandle } from "react-base-virtual-list"; export default function BaseExample() { const ref = useRef(null); @@ -135,8 +135,8 @@ interface VirtualListHandle { 你也可以使用如下第三方 CDN 的地址引入。 -- unpkg: https://unpkg.com/@phphe/react-base-virtual-list -- jsdelivr: https://cdn.jsdelivr.net/npm/@phphe/react-base-virtual-list +- unpkg: https://unpkg.com/react-base-virtual-list +- jsdelivr: https://cdn.jsdelivr.net/npm/react-base-virtual-list ## 开发指南 diff --git a/package.json b/package.json index da4aaec..aa9d475 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "@phphe/react-base-virtual-list", + "name": "react-base-virtual-list", "version": "0.0.1-beta.13", "license": "MIT", "author": "phphe (https://github.com/phphe)", @@ -55,4 +55,4 @@ "vite": "^5.0.8", "vite-plugin-dts": "^3.7.2" } -} +} \ No newline at end of file diff --git a/src/App.tsx b/src/App.tsx index 6f8efe5..7d23327 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -6,7 +6,7 @@ function App() { return ( <>
- @phphe/react-base-virtual-list + react-base-virtual-list Github