mirror of
https://github.com/vale981/Vulcan
synced 2025-03-10 12:36:39 -04:00
21 lines
No EOL
356 B
JavaScript
21 lines
No EOL
356 B
JavaScript
/*
|
|
|
|
Comments views
|
|
|
|
*/
|
|
|
|
import { Comments } from './index.js';
|
|
|
|
Comments.addView('postComments', function (terms) {
|
|
return {
|
|
selector: {postId: terms.postId},
|
|
options: {sort: {postedAt: -1}}
|
|
};
|
|
});
|
|
|
|
Comments.addView('userComments', function (terms) {
|
|
return {
|
|
selector: {userId: terms.userId},
|
|
options: {sort: {postedAt: -1}}
|
|
};
|
|
}); |