Skip to content

Commit

Permalink
docs: ssr users (#5120)
Browse files Browse the repository at this point in the history
* docs: ssr users

* chore: about-alipay
  • Loading branch information
ycjcl868 authored Jul 29, 2020
1 parent 220711e commit 656dd01
Show file tree
Hide file tree
Showing 3 changed files with 99 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/docs/ssr.md
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,10 @@ $ ANALYZE=1 umi build

<img width="600" style="box-shadow: rgba(0, 0, 0, 0.15) 0px 3px 6px 0px;" src="https://user-images.githubusercontent.com/13595509/80446129-8b8ac700-8948-11ea-82a8-54d94501a672.png" />

## 谁在使用?

<code src="./ssrUsers.tsx" inline />

## FAQ

### window is not defined, document is not defined, navigator is not defined
Expand Down
4 changes: 4 additions & 0 deletions docs/docs/ssr.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -562,6 +562,10 @@ $ ANALYZE=1 umi build

<img width="600" style="box-shadow: rgba(0, 0, 0, 0.15) 0px 3px 6px 0px;" src="https://user-images.githubusercontent.com/13595509/80446129-8b8ac700-8948-11ea-82a8-54d94501a672.png" />

## 谁在使用?

<code src="./ssrUsers.tsx" inline />

## FAQ

### window is not defined, document is not defined, navigator is not defined
Expand Down
91 changes: 91 additions & 0 deletions docs/docs/ssrUsers.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
/* eslint-disable react/jsx-no-target-blank */

import React from 'react';

const USERS = [
{
name: '蚂蚁集团官网',
link: 'https://www.antgroup.com',
logo: 'https://img.alicdn.com/tfs/TB1olOTGXY7gK0jSZKzXXaikpXa-2145-498.png',
},
{
name: '罗汉堂官网',
link: 'https://www.luohanacademy.com/',
logo:
'https://gw.alipayobjects.com/mdn/rms_6ab82c/afts/img/A*qPp4QKXu5HQAAAAAAAAAAABkARQnAQ',
},
{
name: '关于支付宝',
link: 'https://about.alipay.com/',
logo: 'https://gw.alipayobjects.com/zos/rmsportal/bsLuElJnYSyLnSOLjKth.png',
},
{
name: 'INCLUSION 外滩大会',
link: 'https://www.inclusionconf.com/',
logo:
'https://gw.alipayobjects.com/mdn/rms_60f090/afts/img/A*nipGQJEKyWEAAAAAAAAAAABkARQnAQ',
},
{
name: 'Alipay Mini Program',
link: 'https://miniprogram.alipay.com/docs/',
logo:
'https://ac.alipay.com/storage/2020/7/21/3ba523c1-ec48-48fc-9618-52302d05e01c.svg',
},
{
name: '菜鸟网络官网',
link: 'https://www.cainiao.com/',
logo: 'https://gw.alicdn.com/tfs/TB1j3vTRXXXXXb8aXXXXXXXXXXX-342-120.png',
},
];

export default () => {
return (
<ul
style={{
display: 'flex',
flexWrap: 'wrap',
margin: 0,
padding: 0,
listStyle: 'none',
}}
>
{USERS.map((user, i) => (
<li
key={user.link}
style={{
width: 280,
marginRight: i === USERS.length - 1 ? 0 : 16,
marginBottom: 8,
border: '1px solid #eee',
textAlign: 'center',
fontSize: 20,
fontWeight: 600,
borderRadius: 2,
}}
>
<a
style={{
display: 'block',
color: '#666',
padding: '18px 32px',
textDecoration: 'none',
}}
target="_blank"
href={user.link}
>
<img
style={{
maxWidth: '100%',
marginBottom: 16,
}}
height="56"
src={user.logo}
alt={user.name}
/>
<p style={{ margin: 0 }}>{user.name}</p>
</a>
</li>
))}
</ul>
);
};

0 comments on commit 656dd01

Please sign in to comment.