Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Voting and commenting for posts and comments #115

Merged
merged 2 commits into from May 23, 2016
Merged

Voting and commenting for posts and comments #115

merged 2 commits into from May 23, 2016

Conversation

ajacksified
Copy link
Contributor

馃憮 @schwers

@@ -2,6 +2,8 @@ import RedditModel from './RedditModel';
import Record from '../apiBase/Record';
import { COMMENT, COMMENT_LOAD_MORE } from './thingTypes';

import votable from './mixins/votable';
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How do we feel about this style of adding functionality? We could also consider decorators as a cleaner syntax.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is fine. I'm hesitant to add decorators to node-build yet as the spec is in flux (more info). From what I've read the new spec isn't completely backwards-compatible, and adding the babel-plugin for the 'legacy' syntax can interact with the static properties plugin in obscure, error'ing, ways. It might be better now so maybe thats worth re-considering

@ajacksified ajacksified changed the title Voting mixin for posts and comments Voting and commenting for posts and comments May 23, 2016
export function _vote (apiOptions, direction) {
const oldModel = this;

const stub = this.stub('likes', direction, async (resolve, reject) => {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

馃敃 馃挴

@schwers-zz
Copy link

馃悷

@ajacksified ajacksified merged commit a2dcad0 into reddit:3X May 23, 2016
@ajacksified ajacksified deleted the upvotes branch May 23, 2016 20:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants