Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require 'sinatra'
- require 'twitter'
- get '/' do
- # Assign the parameter value of `query` to the instance variable `@query`
- @query = params['query']
- client = Twitter::Client.new
- tweet_container = client.search(@query)
- @tweets = tweet_container.results
- erb :index
- end
- get '/about_me' do
- erb :about_me
- end
Add Comment
Please, Sign In to add comment