Clean file
This commit is contained in:
parent
12a4ca7989
commit
5fe69fe18c
20
.eleventy.js
20
.eleventy.js
|
|
@ -7,28 +7,22 @@ module.exports = config => {
|
|||
|
||||
config.addLayoutAlias('base', 'layouts/base.html');
|
||||
|
||||
|
||||
config.addCollection("subpages", (collectionApi) => {
|
||||
// const sections = collectionApi.getFilteredByTag( "subpage" )
|
||||
const sections = collectionApi.getFilteredByGlob("./src/pages/subpages/**")
|
||||
.sort((a, b) => a.data.pageOrderId - b.data.pageOrderId);
|
||||
.sort((a, b) => a.data.order - b.data.order);
|
||||
process.env.DEBUG && console.log(inspect(sections));
|
||||
return sections;
|
||||
});
|
||||
config.addCollection("projects", (collectionApi) => {
|
||||
// const sections = collectionApi.getFilteredByTag( "subpage" )
|
||||
const sections = collectionApi.getFilteredByGlob("./src/projects/**")
|
||||
.sort((a, b) => a.data.pageOrderId - b.data.pageOrderId);
|
||||
process.env.DEBUG && console.log(inspect(sections));
|
||||
return sections;
|
||||
const projects = collectionApi.getFilteredByGlob("./src/projects/**")
|
||||
.sort((a, b) => a.data.order - b.data.order);
|
||||
process.env.DEBUG && console.log(inspect(projects));
|
||||
return projects;
|
||||
});
|
||||
|
||||
|
||||
// config.addCollection('projects', collection => {
|
||||
// return [...collection.getFilteredByGlob('./src/projects/*.md')].reverse();
|
||||
// });
|
||||
config.addCollection('experiences', collection => {
|
||||
return [...collection.getFilteredByGlob('./src/experiences/*.md')].reverse();
|
||||
return [...collection.getFilteredByGlob('./src/experiences/*.md')]
|
||||
.sort((a, b) => a.data.startDate - b.data.startDate).reverse();
|
||||
});
|
||||
|
||||
return {
|
||||
|
|
|
|||
Loading…
Reference in a new issue