Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #288 from beautifulinteractions/feature/v1
Typescript rewrite (version 1.0.0)
- Loading branch information
Showing
145 changed files
with
2,077 additions
and
2,303 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,3 @@ | |
/docs | ||
/test | ||
/docs | ||
index.d.ts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module.exports = { | ||
presets: ['@babel/react', '@babel/env'] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,20 @@ | ||
# Getting started | ||
|
||
|
||
Using `npm`: | ||
|
||
```bash | ||
$ npm i --save beautiful-react-hooks | ||
``` | ||
|
||
Using `yarn`: | ||
|
||
```bash | ||
$ yarn add beautiful-react-hooks | ||
``` | ||
|
||
then just import any hook described by the documentation in your React component file: | ||
|
||
```js | ||
import { useSomeHook } from 'beautiful-react-hooks'; | ||
``` | ||
```ts static | ||
import { useSomeHook } from 'beautiful-react-hooks' | ||
import useSomeHook from 'beautiful-react-hoks/useSomeHook' | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import React from 'react' | ||
import PropTypes from 'prop-types' | ||
import Styled from 'rsg-components/Styled' | ||
import logo from './_doc-logo.png' | ||
|
||
const styles = ({ fontFamily, color }) => ({ | ||
logo: { | ||
display: 'block' | ||
}, | ||
image: { | ||
width: '100%' | ||
} | ||
}) | ||
|
||
const LogoRenderer = ({ classes }) => ( | ||
<h1 className={classes.logo}> | ||
<img className={classes.image} src={logo} alt="Beautiful React Hooks" /> | ||
</h1> | ||
) | ||
|
||
LogoRenderer.propTypes = { | ||
classes: PropTypes.object.isRequired, | ||
children: PropTypes.node | ||
} | ||
|
||
export default Styled(styles)(LogoRenderer) |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.