Describe the bug
Example code in the README doesn't work
To Reproduce
Steps to reproduce the behavior:
- npm install twitter-text, import twitter from 'twitter-text',
twttr.txt.parseTweet(tweet);, run the script
ReferenceError: twttr is not defined
Expected behavior
Example code should work to parse tweet
The fix for this is to write:
var twitter = require('twitter-text');
var tweet = "This is a test tweet";
console.log(twitter.parseTweet(tweet));
Describe the bug
Example code in the README doesn't work
To Reproduce
Steps to reproduce the behavior:
twttr.txt.parseTweet(tweet);, run the scriptReferenceError: twttr is not definedExpected behavior
Example code should work to parse tweet
The fix for this is to write: