Conversation
Addressed some potential code style issues in further commits. Should be all done now. |
Didn't appreciate that the 'close and comment' button would close the pull request and not the comment box |
815d6a6
to
319beaf
Compare
@samph thanks a lot for contributing, we really appreciate it! 😃 We'll be sure to review this shortly and give you some feedback. Also, this is about our 3rd Reddit IA. I'm thinking we should start namespacing them under Or we could just name them RedditThread, RedditUser, RedditSubReddit? I guess seeing similar files/things in an aptly named folder/directory just makes me happy :) |
I'm not especially fussed either way; however namespacing seems tidier |
return time; | ||
}); | ||
|
||
Spice.registerHelper("reddit_user_search_friendly_account_age", function(timestamp){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We've now added support for moment.js. If you wrap the Spice.add()
call in DDG.require('moment.js', function() { ... });
you'll be able to use moment()
which should reduce this function considerable!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Documentation for moment.js is over here http://momentjs.com/
Ping! @samph are you still interested in finishing this up? We'd love to see it go live! |
Thanks for the reminder! Hopefully I'll submit an update taking all the comments into account over the weekend.
|
@samph ping! Just checking in to see if you're still in interested in finishing this up? There's no rush, but we'd love to see it go live! |
Closing for now, we can always re-open later if you'd like to finish this up! |
Spice Pull Request Template
Using this template will help us better understand your Instant Answer and assist you when necessary. Simply copy and paste the markdown below into the description of your GitHub pull request and complete as appropriate.
What does your Instant Answer do?
Returns account information about reddit user accounts
What problem does your Instant Answer solve (Why is it better than organic links)?
Direct information about a reddit account, rather than having to click through to find it on reddit user page
What is the data source for your Instant Answer? (Provide a link if possible)
https://www.reddit.com/user/reddit/about.json
Why did you choose this data source?
Its the official reddit API endpoint
Are there any other alternative (better) data sources?
No
What are some example queries that trigger this Instant Answer?
reddit user alienth
reddit user krispykrackers
Which communities will this Instant Answer be especially useful for? (gamers, book lovers, etc)
Reddit users, those looking for reddit users
Is this Instant Answer connected to a DuckDuckHack Instant Answer idea?
No
Which existing Instant Answers will this one supersede/overlap with?
IAs exist for general reddit post search and subreddit search, but I believe there is little to no overlap.
Are you having any problems? Do you need our help with anything?
N/A
What are the terms of use for the API? Will DuckDuckGo need specific authorization (e.g. an API key)? Are there any costs associated with API usage?
I am not aware of specific issues, and usage/terms will be no different to existing reddit search and reddit subreddit search IAs. API keys and authorisations are not required and there are no associated costs.
Where did you hear about DuckDuckHack? (For first time contributors)
N/A (HackerNews)
What does the Instant Answer look like? (Provide a screenshot for new or updated Instant Answers)
Checklist
Please place an 'X' where appropriate.