Pour tout problème contactez-nous par mail : support@froggit.fr | La FAQ :grey_question: | Rejoignez-nous sur le Chat :speech_balloon:

Skip to content
Snippets Groups Projects
template.js 2.91 KiB
Newer Older
peter_rabbit's avatar
peter_rabbit committed
"use strict";

class Template {
    constructor(props) {
        this.props = props;
    }

    render() {
        return {
            tag: "main",
            contents: [
                {
                    tag: "header",
                    contents: [
                        {
                            tag: "ul",
                            contents: [
                                {
                                    tag: "li",
                                    contents: [
                                        {
                                            tag: "a",
                                            href: "/public/",
                                            contents: "Home",
                                        },
                                    ],
                                },
                                {
                                    tag: "li",
                                    contents: [
                                        {
                                            tag: "a",
                                            href: "/public/games/",
                                            contents: "Jeux",
                                        },
                                    ],
                                },
                                {
                                    tag: "li",
                                    contents: [
                                        {
                                            tag: "a",
                                            href: "/public/software-development/",
                                            contents: "Software development",
                                        },
                                    ],
                                },
                                {
                                    tag: "li",
                                    contents: [
                                        {
                                            tag: "a",
                                            href: "/public/education/",
                                            contents: "Pédagogie",
                                        },
                                    ],
                                },
                            ],
                        },
                    ],
                },
                {
                    tag: "div",
                    id: "page-container",
                    contents: [this.props.page.render()],
                },
                {
                    tag: "footer",
                    contents: [
                        {
                            tag: "a",
                            href: "mailto:kuadrado-software@tutanota.com",
                            contents: "kuadrado-software@tutanota.com",
                        },
                    ],
                },
            ],
        };
    }
}

module.exports = Template;