From 8ab00d99fa2f14ac983f0693552b26e4050a939c Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Thu, 23 Mar 2023 15:00:59 -0300 Subject: data steps: content function evaluation essentials Also some more actual content in generateAlbumInfoPageContent, which is in fact fully working as-is(!!). --- src/content/dependencies/linkArtist.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'src/content/dependencies/linkArtist.js') diff --git a/src/content/dependencies/linkArtist.js b/src/content/dependencies/linkArtist.js index 396eca41..718ee6fa 100644 --- a/src/content/dependencies/linkArtist.js +++ b/src/content/dependencies/linkArtist.js @@ -1,9 +1,8 @@ export default { - data(artist) { - return {directory: artist.directory}; - }, + contentDependencies: ['linkThing'], - generate(data) { - return `(stub artist link: "${data.directory}")`; - }, + relations: (relation, artist) => + ({link: relation('linkThing', 'localized.artist', artist)}), + + generate: (relations) => relations.link, }; -- cgit 1.3.0-6-gf8a5