Star

linkAuthor Information

You can easily provide author and publishing (latest publish date) information using Author markdown component:

1link> :Author name=Jackie Chan, <!--> name of the author -->

2link> date=Today, <!--> last publish date (of this article) -->

3link> avatar=https://www.sueddeutsche.de/image/sz.1.1643818/704x396?v=1522204548, <!--> avatar URL -->

4link> url=https://en.wikipedia.org/wiki/Jackie_Chan <!--> author profile URL -->


The Author component accepts the following attributes:


linkAutomatic Inference

If your blog is hosted on GitHub, the Author component can also automatically fetch all necessary information from GitHub. In that case, instead of all the aforementioned attributes, just set src attribute to github:

1link> :Author src=github


For automatic inference, name, avatar and GitHub profile of the author will be used (the user with last commit on the markdown file). The last publish date will also be set to the date of the last commit on the markdown file.

warning IMPORTANT

For automatic inference to work, you need to configure your blog's github repository properly, via .codedoc/config.ts:

.codedoc/config.ts
1linkimport { configuration } from '@codedoc/core';

2link

3link//...

4link

5linkexport const config = /*#__PURE__*/configuration({

6link //...

7link misc: {

8link github: {

9link user: 'johndoe', // --> name of the user on GitHub owning the repo

10link repo: 'my-blog', // --> name of the repo on GitHub

11link },

12link // ...

13link },

14link //...

15link});

When using automatic inference, you can also override the publish date by providing the date attribute:

1link> :Author src=github, date=4 Apr 1968



Hero image by Da Kraplak from Unsplash


Author InformationAutomatic Inference

Home Hero Images Titles Author Info Article Cards Tags RSS Miscellaneous Assets