@ta-interaktiv/react-article-teasers
TypeScript icon, indicating that this package has built-in type declarations

4.2.0 • Public • Published

ArticleTeasers

Show a row of article teasers according to a list of article IDs.

npm version

Installation

yarn add @ta-interaktiv/react-article-teasers

Usage

Examples

import React from 'react'
import { ArticleTeasers, SortMode } from '@ta-interaktiv/react-article-teasers'

// more code ...

class YourComponent extends React.Component {
  render() {
    return (
      <ArticleTeasers
        sorting={SortMode.REVERSE_CHRONOLOGICALLY_BY_CREATION_DATE}
        articleIds={['16008934', '21426105', '17814575']}
      />
    )
  }
}
import React from 'react'
import { ArticleCard } from '@ta-interaktiv/react-article-teasers'
function MyComponent(props) {
  return (
    <ArticleCard
      url='https://www.tagesanzeiger.ch'
      imageSrc='https://interaktiv.tagesanzeiger.ch/teaser.jpg'
      title='Schlagzeile'
      lead='<p>Das müssen Sie gelesen haben.</p>'
      authors='Interaktiv-Team'
    />
  )
}

Documentation

Can be found here.

Package Sidebar

Install

npm i @ta-interaktiv/react-article-teasers

Weekly Downloads

291

Version

4.2.0

License

ISC

Unpacked Size

120 kB

Total Files

27

Last publish

Collaborators

  • s1co
  • dariush-mehdiaraghi
  • mrdz_tx
  • mathiaslutz
  • sebaa