@twreporter/react-article-components
v2.5.5
Published
The Reporter react article components, which are used in article page
Downloads
1,054
Keywords
Readme
twreporter-react-components
What is this
The React components of articles at The Reporter Taiwan.
Published as an npm package.
Why do we this
This is built for twreporter-react and Editorial Tool (you can build the editorial tool using Plate). These Article React Components will be used on Article Page and Editorial Tool.
How to install this
yarn add @twreporter/react-article-components
How to use this
// es6
import Article from '@twreporter/react-article-components'
const Page = ({ record }) => <Article post={record} />
How to develop this
There are two dev modes:
We use
webpack-dev-server
to render a mock article with all elements for development.# Start the webpack-dev-server npm run dev-server
Or use
babel --watch
to complie the source file if there's any change happenedmake dev
How to build this
# Build the distribution files
make build