Created
December 11, 2016 18:37
-
-
Save thiagoa/684f3b5095ae8409081f6ad77f9221d6 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| import { pipe } from 'lodash/fp'; | |
| import wrapSentencesInTags from 'app/twitter/wrapSentencesInTags'; | |
| import parseLineBreaks from 'app/twitter/parseLineBreaks'; | |
| import parseTweetMentions from 'app/twitter/parseTweetMentions'; | |
| const parseText = pipe(parseTweetMentions, wrapSentencesInTags, parseLineBreaks); | |
| export default function parseOneTweet(tweet) { | |
| return Object.assign({}, tweet, { text: parseText(tweet) }); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment