1. 使用您喜欢的软件包管理器安装npm软件包

# npm
npm install --save @notice-org/react

# yarn
yarn add @notice-org/react

# pnpm
pnpm install @notice-org/react






🌱

2. You can now import and use the Notice component everywhere

import { Notice } from '@notice-org/react'

const AnyReactComponent = () => {
  return <Notice pageId="{{{project}}}" />
}







3. 而且您可以添加任何这些道具

<Notice
  pageId="string" // required
  lang="string" // optionnal
  theme="light | dark" // optionnal
  navigationType="query | memory" // default to memory
/>

// You can also pass children to this component that will act as a loading state
<Notice pageId="...">
  <span>Loading...</span>
</Notice>







示例沙盒


由 Notice 创建