How to use react-native-htmlview - 1 common examples

To help you get started, we’ve selected a few react-native-htmlview examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github JetBrains / youtrack-mobile / src / components / wiki / wiki.js View on Github external
import {Linking, Text} from 'react-native';
import React, {PureComponent} from 'react';
import HTMLView from 'react-native-htmlview';
import toHtml from 'htmlparser-to-html';

import Router from '../router/router';
import styles, {htmlViewStyles} from './wiki.styles';
import {COLOR_FONT} from '../variables/variables';
import {getBaseUrl} from '../config/config';
import {renderCode, renderImage, renderTable, renderTableRow, renderTableCell} from './wiki__renderers';
import {extractId} from '../open-url-handler/open-url-handler';
import {showMoreInlineText} from '../text-view/text-view';
import {hasMimeType} from '../mime-type/mime-type';
import {nodeHasType} from './wiki__node-type';

HTMLView.propTypes.style = Text.propTypes.style;

type Props = {
  style?: any,
  children?: React$Element,
  attachments: Array,
  imageHeaders: ?Object,
  backendUrl: string,
  onIssueIdTap: (issueId: string) => any,
  title?: string,
  renderFullException?: boolean
};

const HTML_RENDER_NOTHING = null;
const HTML_RENDER_DEFAULT = undefined;
const RootComponent = props =>

react-native-htmlview

A component which renders HTML content as native views

ISC
Latest version published 1 year ago

Package Health Score

65 / 100
Full package analysis

Popular react-native-htmlview functions