{"_id":"react-native-highlight-words","_rev":"7-e5b3d51e41ccb45e98de457ee663fd35","name":"react-native-highlight-words","description":"A React Native port of react-highlight-words. This component is used to highlight words within a larger body of text.","dist-tags":{"latest":"1.0.1"},"versions":{"1.0.0":{"name":"react-native-highlight-words","version":"1.0.0","description":"A React Native port of react-highlight-words. This component is used to highlight words within a larger body of text.","main":"index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"git+https://github.com/clauderic/react-native-highlight-words.git"},"keywords":["react-native","react","reactjs","react-component","highlighter","highlight","text","words","matches","substring","occurrences","search"],"author":{"name":"Clauderic Demers"},"license":"MIT","bugs":{"url":"https://github.com/clauderic/react-native-highlight-words/issues"},"homepage":"https://github.com/clauderic/react-native-highlight-words","dependencies":{"highlight-words-core":"^1.0.3"},"gitHead":"34cbb22cf1e31ef7ff3fce2b4592f8fb910bfd56","_id":"react-native-highlight-words@1.0.0","_shasum":"550bc9b42f2e029d06e59a749b60f676a22156b7","_from":".","_npmVersion":"2.14.7","_nodeVersion":"4.2.1","_npmUser":{"name":"clauderic","email":"clauderic.d@gmail.com"},"dist":{"shasum":"550bc9b42f2e029d06e59a749b60f676a22156b7","tarball":"https://registry.npmjs.org/react-native-highlight-words/-/react-native-highlight-words-1.0.0.tgz","integrity":"sha512-hgF+BBoP3Mdf8k6RCjqeszZo/iopD9G1U2pgZ8MdpYh2gNVbPFG+nr+DD4bo1bonImUbYG8HsoigtVxtwPbDrA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEtO/zzN7STbCkQLpgZoVLIXr5EYfHwa4rs0ONjGmCujAiADh13q9qAvlXloSneuz4qu/OGBU0rdId4OI9NkEUHaTQ=="}]},"maintainers":[{"name":"clauderic","email":"clauderic.d@gmail.com"}],"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/react-native-highlight-words-1.0.0.tgz_1474511570483_0.36018522270023823"},"directories":{}},"1.0.1":{"name":"react-native-highlight-words","version":"1.0.1","description":"A React Native port of react-highlight-words. This component is used to highlight words within a larger body of text.","main":"index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"git+https://github.com/clauderic/react-native-highlight-words.git"},"keywords":["react-native","react","reactjs","react-component","highlighter","highlight","text","words","matches","substring","occurrences","search"],"author":{"name":"Clauderic Demers"},"license":"MIT","bugs":{"url":"https://github.com/clauderic/react-native-highlight-words/issues"},"homepage":"https://github.com/clauderic/react-native-highlight-words","dependencies":{"highlight-words-core":"^1.0.3","prop-types":"^15.5.7"},"peerDependencies":{"react":"^15.5.0"},"gitHead":"58aaeb689d28f4f905f1988dcefb611d345b1838","_id":"react-native-highlight-words@1.0.1","_npmVersion":"5.4.2","_nodeVersion":"6.9.4","_npmUser":{"name":"clauderic","email":"clauderic.d@gmail.com"},"dist":{"integrity":"sha512-cza6kbXeX2bWIwog6iatcMoWX6xogWvSKK1esCA7EQnQ/2hmqvdYGdGjvzTwLXyLmcBRySgreARNNKuDrKh7dg==","shasum":"d998f8eb88765820367c6e8a12e1392df7fd58c7","tarball":"https://registry.npmjs.org/react-native-highlight-words/-/react-native-highlight-words-1.0.1.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFRM457Vk4s2+Y1rVLsoYT7q/rRLauZFzT6oE/BslT26AiAx4KHee452aazfDsdU3a0hKLEFyNhhXgJDYHxlU1lHRA=="}]},"maintainers":[{"name":"bvaughn","email":"briandavidvaughn@gmail.com"},{"name":"clauderic","email":"clauderic.d@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-highlight-words-1.0.1.tgz_1512754422576_0.5375678401906043"},"directories":{}}},"readme":"# React Native Highlight Words\nReact Native component used to highlight words within a larger body of text. This is a port of [react-highlight-words](https://github.com/bvaughn/react-highlight-words).\n\nCheck out a [demo](https://getexponent.com/@clauderic/react-native-highlight-words) using Exponent.\n\n## Installation\nUsing [npm](https://www.npmjs.com/package/react-native-highlight-words):\n```\nnpm i --save react-native-highlight-words\n```\n\n## Usage\n\nTo use it, just provide it with an array of search terms and a body of text to highlight:\n\n```jsx\nimport Highlighter from 'react-native-highlight-words';\n\n<Highlighter\n  highlightStyle={{backgroundColor: 'yellow'}}\n  searchWords={['and', 'or', 'the']}\n  textToHighlight='The dog is chasing the cat. Or perhaps they're just playing?'\n/>\n```\n\nAnd the `Highlighter` component will highlight all occurrences of search terms within the text:\n\n<img width=\"368\" alt=\"screen shot 2015-12-19 at 8 23 43 am\" src=\"https://cloud.githubusercontent.com/assets/29597/11914033/e3c319f6-a629-11e5-896d-1a5ce22c9ea2.png\">\n\n\n## Props\n\n| Property        | Type          | Required? | Description                                                                                                             |\n|:----------------|:--------------|:---------:|:------------------------------------------------------------------------------------------------------------------------|\n| autoEscape      | Boolean       |           | Escape characters which are meaningful in regular expressions                                                           |\n| highlightStyle  | Object        |           | Styles applied to highlighted text                                                                                      |\n| sanitize        | Function      |           | Process each search word and text to highlight before comparing (eg remove accents); signature `(text: string): string` |\n| searchWords     | Array<String> |     ✓     | Array of search words                                                                                                   |\n| style           | Object        |           | Styles applied to the text wrapper                                                                                      |\n| textToHighlight | String        |     ✓     | Text to highlight matches in                                                                                            |\n\n## License\nMIT License - fork, modify and use however you want.\n\n<a target='_blank' rel='nofollow' href='https://app.codesponsor.io/link/oN9PDWZz8fQcbh9sxpDEUvD5/clauderic/react-native-highlight-words'>  <img alt='Sponsor' width='888' height='68' src='https://app.codesponsor.io/embed/oN9PDWZz8fQcbh9sxpDEUvD5/clauderic/react-native-highlight-words.svg' /></a>\n","maintainers":[{"email":"clauderic.d@gmail.com","name":"clauderic"}],"time":{"modified":"2022-08-15T13:02:01.033Z","created":"2016-09-22T02:32:52.516Z","1.0.0":"2016-09-22T02:32:52.516Z","1.0.1":"2017-12-08T17:33:43.735Z"},"homepage":"https://github.com/clauderic/react-native-highlight-words","keywords":["react-native","react","reactjs","react-component","highlighter","highlight","text","words","matches","substring","occurrences","search"],"repository":{"type":"git","url":"git+https://github.com/clauderic/react-native-highlight-words.git"},"author":{"name":"Clauderic Demers"},"bugs":{"url":"https://github.com/clauderic/react-native-highlight-words/issues"},"license":"MIT","readmeFilename":"README.md"}