UNPKG

666 BJavaScriptView Raw
1"use strict";
2
3var url = require("url");
4var e = require("./element");
5
6// TODO: Push to another package or use a pre-existing one over this
7module.exports = function (_ref) {
8 var baseUrl = _ref.baseUrl,
9 _ref$sections = _ref.sections,
10 sections = _ref$sections === undefined ? [] : _ref$sections,
11 updated = _ref.updated,
12 pages = _ref.pages,
13 config = _ref.config,
14 get = _ref.get;
15
16 return e.feed([e.title(config.title), e.link(url.resolve(baseUrl, "/atom.xml"), "self"), e.link(baseUrl), e.updated(updated), e.id(baseUrl), e.author(config.author), e.entries({ baseUrl: baseUrl, sections: sections, pages: pages, get: get })]);
17};
\No newline at end of file