Compare commits
No commits in common. "a7f874c64fb4697ac4b769c0ce448a3ba9ca9250" and "f9a908e3f032e782d51dde75c5c87e19b39802d7" have entirely different histories.
a7f874c64f
...
f9a908e3f0
@ -1,24 +0,0 @@
|
|||||||
---
|
|
||||||
title: Certifications Memento Dev
|
|
||||||
description: Tu te prépares à passer un examen de certification, comme DWWM, CDA ou encore CDUI ? Découvre donc de bons conseils pour t'aider à te préparer au mieux !
|
|
||||||
tags: []
|
|
||||||
---
|
|
||||||
|
|
||||||
Tu te prépares à passer un examen de certification, comme DWWM, CDA ou encore CDUI ?
|
|
||||||
Découvre donc de bons conseils pour t'aider à te préparer au mieux !
|
|
||||||
|
|
||||||
## Certifications couvertes sur le Memento
|
|
||||||
|
|
||||||
- **DWWM** : Développeur Web et Web Mobile
|
|
||||||
- **CDA** : Concepteur Développeur d'Applications
|
|
||||||
- **CDUI** : Concepteur Développeur d'Interfaces Utilisateurs
|
|
||||||
|
|
||||||
## Besoin d'un accompagnement ?
|
|
||||||
|
|
||||||
{% callout type="note" title="Accompagnement" %}
|
|
||||||
En qualité de jury habilité sur les titres professionnels **DWWM**, **CDA** et **CDUI**, je peux t'accompagner dans ta préparation à l'examen.
|
|
||||||
|
|
||||||
Qu'il s'agisse d'une aide à la **compréhension des référentiels**, d'une **préparation à l'oral** ou d'un **accompagnement sur un projet**, je suis là pour t'aider à réussir !
|
|
||||||
|
|
||||||
Tu peux me contacter par [email _(gauthier@gauthierdaniels.fr)_](mailto:gauthier@gauthierdaniels?subject=Demande%20d'accompagnement%20pour%20le%20titre%20professionnel%20X) pour bénéficier d'un accompagnement personnalisé et de conseils adaptés à tes besoins.
|
|
||||||
{% /callout %}
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
---
|
|
||||||
title: Documentations du Memento
|
|
||||||
description: Plonge toi dans une documentation synthétique et concise, conçue pour les développeurs ou passionnés de l'information en quête de savoir !
|
|
||||||
tags: []
|
|
||||||
---
|
|
||||||
|
|
||||||
## Documentations rédigées
|
|
||||||
|
|
||||||
- [React](/docs/react)
|
|
||||||
|
|
||||||
## Documentations en cours de rédaction
|
|
||||||
|
|
||||||
- [Merise](/docs/merise)
|
|
||||||
|
|
||||||
## Documentations à venir
|
|
||||||
|
|
||||||
- HTML
|
|
||||||
- CSS
|
|
||||||
- JavaScript
|
|
||||||
- PHP
|
|
||||||
- SQL
|
|
||||||
- Node.js
|
|
||||||
- Express.js
|
|
||||||
- UML
|
|
||||||
- Maquettage
|
|
||||||
|
|
||||||
Et bien d'autres encore ! 😄
|
|
||||||
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
title: Synthèses et ressources pour développeurs
|
title: Documentation Memento Dev
|
||||||
description: Plonge toi dans une documentation synthétique et concise, conçue pour les développeurs ou passionnés de l'information en quête de savoir !
|
description: Plonge toi dans une documentation synthétique et concise, conçue pour les développeurs ou passionnés de l'information en quête de savoir !
|
||||||
tags: []
|
tags: []
|
||||||
---
|
---
|
||||||
|
|||||||
@ -1,16 +1,10 @@
|
|||||||
export const navigation = [
|
export const navigation = [
|
||||||
{
|
{
|
||||||
title: "Préambule",
|
title: "Préambule",
|
||||||
type: "global",
|
links: [{ title: "Memento Dev", href: "/docs" }],
|
||||||
links: [
|
|
||||||
{ title: "Memento Dev", href: "/" },
|
|
||||||
{ title: "Certifications", href: "/certifications" },
|
|
||||||
{ title: "Documentations", href: "/docs" },
|
|
||||||
],
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "React",
|
title: "React",
|
||||||
type: "documentation",
|
|
||||||
links: [
|
links: [
|
||||||
{ title: "Introduction", href: "/docs/react" },
|
{ title: "Introduction", href: "/docs/react" },
|
||||||
{ title: "Initialisation", href: "/docs/react/initialisation" },
|
{ title: "Initialisation", href: "/docs/react/initialisation" },
|
||||||
@ -24,7 +18,6 @@ export const navigation = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "Merise",
|
title: "Merise",
|
||||||
type: "documentation",
|
|
||||||
links: [
|
links: [
|
||||||
{ title: "Introduction", href: "/docs/merise" },
|
{ title: "Introduction", href: "/docs/merise" },
|
||||||
{ title: "Dictionnaire de données", href: "/docs/merise/dictionnaire-de-donnees" },
|
{ title: "Dictionnaire de données", href: "/docs/merise/dictionnaire-de-donnees" },
|
||||||
@ -33,7 +26,6 @@ export const navigation = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: "Communauté",
|
title: "Communauté",
|
||||||
type: "global",
|
|
||||||
links: [
|
links: [
|
||||||
{ title: "Influenceurs", href: "/docs/communaute/influenceurs" },
|
{ title: "Influenceurs", href: "/docs/communaute/influenceurs" },
|
||||||
{ title: "Partages et réutilisations", href: "/docs/communaute/partages" },
|
{ title: "Partages et réutilisations", href: "/docs/communaute/partages" },
|
||||||
|
|||||||
@ -1,3 +1,6 @@
|
|||||||
|
// https://vike.dev/Head
|
||||||
|
|
||||||
|
import React from "react";
|
||||||
import logoUrl from "../assets/logo.svg";
|
import logoUrl from "../assets/logo.svg";
|
||||||
|
|
||||||
export default function HeadDefault() {
|
export default function HeadDefault() {
|
||||||
|
|||||||
@ -1,7 +1,6 @@
|
|||||||
import type { Config } from "vike/types";
|
|
||||||
|
|
||||||
import Layout from "@/layouts/LayoutDefault";
|
|
||||||
import vikeReact from "vike-react/config";
|
import vikeReact from "vike-react/config";
|
||||||
|
import type { Config } from "vike/types";
|
||||||
|
import Layout from "../layouts/LayoutDefault.js";
|
||||||
|
|
||||||
// Default config (can be overridden by pages)
|
// Default config (can be overridden by pages)
|
||||||
// https://vike.dev/config
|
// https://vike.dev/config
|
||||||
@ -14,7 +13,7 @@ export default {
|
|||||||
|
|
||||||
// https://vike.dev/head-tags
|
// https://vike.dev/head-tags
|
||||||
title: "Memento Dev",
|
title: "Memento Dev",
|
||||||
description: "Découvrez des synthèses et ressources open-source dans le développement informatique.",
|
description: "Demo showcasing Vike",
|
||||||
|
|
||||||
htmlAttributes: {
|
htmlAttributes: {
|
||||||
class: "h-full antialiased",
|
class: "h-full antialiased",
|
||||||
|
|||||||
@ -1,16 +0,0 @@
|
|||||||
import type { Data } from "./+data";
|
|
||||||
|
|
||||||
import { useData } from "vike-react/useData";
|
|
||||||
import Markdoc from "@markdoc/markdoc";
|
|
||||||
import nodes from "@/markdoc/nodes";
|
|
||||||
import tags from "@/markdoc/tags";
|
|
||||||
import React from "react";
|
|
||||||
|
|
||||||
export default function Page() {
|
|
||||||
const { doc, estimatedReadingTime } = useData<Data>();
|
|
||||||
|
|
||||||
const parsedDoc = Markdoc.parse(doc.content);
|
|
||||||
const transformedDoc = Markdoc.transform(parsedDoc, { nodes, tags, variables: { estimatedReadingTime } });
|
|
||||||
|
|
||||||
return Markdoc.renderers.react(transformedDoc, React);
|
|
||||||
}
|
|
||||||
@ -1,38 +0,0 @@
|
|||||||
import type { PageContext } from "vike/types";
|
|
||||||
|
|
||||||
import { snippetsService } from "@/services/SnippetsService";
|
|
||||||
import { docsService } from "@/services/DocsService";
|
|
||||||
import { readingTime } from "reading-time-estimator";
|
|
||||||
import { useConfig } from "vike-react/useConfig";
|
|
||||||
import buildTitle from "@/pages/buildTitle";
|
|
||||||
import { render } from "vike/abort";
|
|
||||||
|
|
||||||
export type Data = Awaited<ReturnType<typeof data>>;
|
|
||||||
|
|
||||||
export async function data(pageContext: PageContext) {
|
|
||||||
const config = useConfig();
|
|
||||||
|
|
||||||
const { key } = pageContext.routeParams;
|
|
||||||
|
|
||||||
const doc = await docsService.getDoc("certifications", key);
|
|
||||||
|
|
||||||
if (!doc) {
|
|
||||||
throw render(404);
|
|
||||||
}
|
|
||||||
|
|
||||||
const readingTimeObject = readingTime(doc.content, 300, "fr");
|
|
||||||
|
|
||||||
config({
|
|
||||||
title: buildTitle(doc.title),
|
|
||||||
description: doc.description,
|
|
||||||
});
|
|
||||||
|
|
||||||
docsService.transform(doc);
|
|
||||||
|
|
||||||
const snippets = Array.from(doc.snippets).map((snippetPath) => ({
|
|
||||||
path: snippetPath,
|
|
||||||
content: snippetsService.getFromCache(snippetPath),
|
|
||||||
}));
|
|
||||||
|
|
||||||
return { doc, estimatedReadingTime: readingTimeObject.text, snippets };
|
|
||||||
}
|
|
||||||
@ -1,16 +0,0 @@
|
|||||||
import type { PageContext } from "vike/types";
|
|
||||||
|
|
||||||
const routeRegex = /^\/certifications\/(.*)$/;
|
|
||||||
|
|
||||||
export function route(pageContext: PageContext) {
|
|
||||||
if (pageContext.urlPathname === "/certifications") {
|
|
||||||
return { routeParams: { key: "index" } };
|
|
||||||
}
|
|
||||||
|
|
||||||
const match = pageContext.urlPathname.match(routeRegex);
|
|
||||||
if (!match) return false;
|
|
||||||
|
|
||||||
const [, key] = match;
|
|
||||||
|
|
||||||
return { routeParams: { key } };
|
|
||||||
}
|
|
||||||
@ -4,7 +4,7 @@ const routeRegex = /^\/docs\/(.*)$/;
|
|||||||
|
|
||||||
export function route(pageContext: PageContext) {
|
export function route(pageContext: PageContext) {
|
||||||
if (pageContext.urlPathname === "/docs") {
|
if (pageContext.urlPathname === "/docs") {
|
||||||
return { routeParams: { key: "documentations" } };
|
return { routeParams: { key: "index" } };
|
||||||
}
|
}
|
||||||
|
|
||||||
const match = pageContext.urlPathname.match(routeRegex);
|
const match = pageContext.urlPathname.match(routeRegex);
|
||||||
|
|||||||
@ -1,16 +1,7 @@
|
|||||||
import type { Data } from "./+data";
|
|
||||||
|
|
||||||
import { useData } from "vike-react/useData";
|
|
||||||
import Markdoc from "@markdoc/markdoc";
|
|
||||||
import nodes from "@/markdoc/nodes";
|
|
||||||
import tags from "@/markdoc/tags";
|
|
||||||
import React from "react";
|
|
||||||
|
|
||||||
export default function Page() {
|
export default function Page() {
|
||||||
const { doc, estimatedReadingTime } = useData<Data>();
|
return (
|
||||||
|
<main className="max-w-2xl min-w-0 flex-auto px-4 py-16 lg:max-w-none lg:pr-0 lg:pl-8 xl:px-16">
|
||||||
const parsedDoc = Markdoc.parse(doc.content);
|
<h1 className={"font-bold text-3xl pb-4"}>My Vike app</h1>
|
||||||
const transformedDoc = Markdoc.transform(parsedDoc, { nodes, tags, variables: { estimatedReadingTime } });
|
</main>
|
||||||
|
);
|
||||||
return Markdoc.renderers.react(transformedDoc, React);
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,36 +0,0 @@
|
|||||||
import type { PageContext } from "vike/types";
|
|
||||||
|
|
||||||
import { snippetsService } from "@/services/SnippetsService";
|
|
||||||
import { docsService } from "@/services/DocsService";
|
|
||||||
import { readingTime } from "reading-time-estimator";
|
|
||||||
import { useConfig } from "vike-react/useConfig";
|
|
||||||
import buildTitle from "@/pages/buildTitle";
|
|
||||||
import { render } from "vike/abort";
|
|
||||||
|
|
||||||
export type Data = Awaited<ReturnType<typeof data>>;
|
|
||||||
|
|
||||||
export async function data(pageContext: PageContext) {
|
|
||||||
const config = useConfig();
|
|
||||||
|
|
||||||
const doc = await docsService.getDoc("docs", "index");
|
|
||||||
|
|
||||||
if (!doc) {
|
|
||||||
throw render(404);
|
|
||||||
}
|
|
||||||
|
|
||||||
const readingTimeObject = readingTime(doc.content, 300, "fr");
|
|
||||||
|
|
||||||
config({
|
|
||||||
title: buildTitle(doc.title),
|
|
||||||
description: doc.description,
|
|
||||||
});
|
|
||||||
|
|
||||||
docsService.transform(doc);
|
|
||||||
|
|
||||||
const snippets = Array.from(doc.snippets).map((snippetPath) => ({
|
|
||||||
path: snippetPath,
|
|
||||||
content: snippetsService.getFromCache(snippetPath),
|
|
||||||
}));
|
|
||||||
|
|
||||||
return { doc, estimatedReadingTime: readingTimeObject.text, snippets };
|
|
||||||
}
|
|
||||||
17
app/pages/index/Counter.tsx
Normal file
17
app/pages/index/Counter.tsx
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
import React, { useState } from "react";
|
||||||
|
|
||||||
|
export function Counter() {
|
||||||
|
const [count, setCount] = useState(0);
|
||||||
|
|
||||||
|
return (
|
||||||
|
<button
|
||||||
|
type="button"
|
||||||
|
className={
|
||||||
|
"inline-block border border-black rounded bg-gray-200 px-2 py-1 text-xs font-medium uppercase leading-normal"
|
||||||
|
}
|
||||||
|
onClick={() => setCount((count) => count + 1)}
|
||||||
|
>
|
||||||
|
Counter {count}
|
||||||
|
</button>
|
||||||
|
);
|
||||||
|
}
|
||||||
@ -152,7 +152,6 @@ class DocsService {
|
|||||||
public async getDoc(namespace: "docs" | "certifications", key: string) {
|
public async getDoc(namespace: "docs" | "certifications", key: string) {
|
||||||
try {
|
try {
|
||||||
await this.fetchDocs();
|
await this.fetchDocs();
|
||||||
console.log(this.cache.keys());
|
|
||||||
const doc = this.getFromCache(`/${namespace}/${key}`);
|
const doc = this.getFromCache(`/${namespace}/${key}`);
|
||||||
|
|
||||||
if (!doc) {
|
if (!doc) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user