Skip to content

Commit

Permalink
doc: 纠正文档错误
Browse files Browse the repository at this point in the history
  • Loading branch information
yyz945947732 committed Aug 28, 2023
1 parent 300a7ea commit 78f2b99
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion READEME.zh-en.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Wrap with `Auth.Provider` component to use.

```typescript
// index.tsx
import { useState } from "react";
import { useState, useEffect } from "react";
import { Auth } from "@gzteacher/auth";

function Layout() {
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ yarn add @gzteacher/auth

```typescript
// index.tsx
import { useState } from "react";
import { useState, useEffect } from "react";
import { Auth } from "@gzteacher/auth";

function Layout() {
Expand Down
2 changes: 1 addition & 1 deletion src/stories/介绍.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ yarn add @gzteacher/auth

```typescript
// index.tsx
import { useState } from "react";
import { useState, useEffect } from "react";
import { Auth } from "@gzteacher/auth";

function Layout() {
Expand Down
6 changes: 3 additions & 3 deletions src/stories/验证器.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export function Example() {
if (__ENV__ === "DEV") {
return true;
} else {
return Boolean(auth[authCode]);
return auth[authCode];
}
},
},
Expand Down Expand Up @@ -188,7 +188,7 @@ export function Example() {
if (auth["admin"]) {
return true;
}
return Boolean(auth[authCode]);
return auth[authCode];
},
},
]}
Expand Down Expand Up @@ -255,7 +255,7 @@ export default [
if (auth["admin"]) {
return true;
}
return Boolean(auth[authCode]);
return auth[authCode];
},
},
];
Expand Down

0 comments on commit 78f2b99

Please sign in to comment.