init project

This commit is contained in:
Tibo
2019-12-17 21:05:34 +01:00
commit 259d1e6e49
16 changed files with 10807 additions and 0 deletions
+4
View File
@@ -0,0 +1,4 @@
Add components that will be imported to Pages and Layouts to this folder.
Learn more about components here: https://gridsome.org/docs/components/
You can delete this file.
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

+24
View File
@@ -0,0 +1,24 @@
<template>
<div class="layout">
<!-- Contient les pages -->
<slot/>
</div>
</template>
<style>
body {
font-family: -apple-system,system-ui,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
margin:0;
padding:0;
line-height: 1.5;
}
.layout {
max-width: 760px;
margin: 0 auto;
padding-left: 20px;
padding-right: 20px;
}
</style>
+5
View File
@@ -0,0 +1,5 @@
Layout components are used to wrap pages and templates. Layouts should contain components like headers, footers or sidebars that will be used across the site.
Learn more about Layouts: https://gridsome.org/docs/layouts/
You can delete this file.
+9
View File
@@ -0,0 +1,9 @@
// This is the main.js file. Import global CSS and scripts here.
// The Client API can be used here. Learn more: gridsome.org/docs/client-api
import DefaultLayout from '~/layouts/Default.vue'
export default function (Vue, { router, head, isClient }) {
// Set default layout as a global component
Vue.component('Layout', DefaultLayout)
}
+29
View File
@@ -0,0 +1,29 @@
<template>
<Layout>
<!-- Mise en page -->
<div v-for="edge in $page.chapitres.edges" :key="edge.node.id">
{{edge.node.titre}}
{{edge.node.contenu}}
</div>
</Layout>
</template>
<script>
export default {
}
</script>
<page-query>
query {
chapitres: allChapitres {
edges {
node {
id
titre
contenu
}
}
}
}
</page-query>
+5
View File
@@ -0,0 +1,5 @@
Pages are usually used for normal pages or for listing items from a GraphQL collection.
Add .vue files here to create pages. For example **About.vue** will be **site.com/about**.
Learn more about pages: https://gridsome.org/docs/pages/
You can delete this file.
+7
View File
@@ -0,0 +1,7 @@
Templates for **GraphQL collections** should be added here.
To create a template for a collection called `WordPressPost`
create a file named `WordPressPost.vue` in this folder.
Learn more: https://gridsome.org/docs/templates/
You can delete this file.