feat: code split & use react helmet

This commit is contained in:
endiliey 2018-08-23 21:46:14 +08:00
parent bf1e30dc52
commit 406106b67e
19 changed files with 241 additions and 146 deletions

15
lib/theme/Loading.js Normal file
View file

@ -0,0 +1,15 @@
import React from 'react';
export default props => {
if (props.error) {
return (
<div>
Error!{' '}
<button type="button" onClick={props.retry}>
Retry
</button>
</div>
);
}
return <div>Loading...</div>;
};