From 983811db4bf200b61a29c01227e7fc0da5e9b807 Mon Sep 17 00:00:00 2001 From: Malik Whitten <65188863+MalikWhitten67@users.noreply.github.com> Date: Thu, 28 Sep 2023 07:31:24 -0500 Subject: [PATCH] Update project-structure.html --- src/views/docs/basics/project-structure.html | 76 +++++++++++--------- 1 file changed, 42 insertions(+), 34 deletions(-) diff --git a/src/views/docs/basics/project-structure.html b/src/views/docs/basics/project-structure.html index 00c8376..27456d6 100644 --- a/src/views/docs/basics/project-structure.html +++ b/src/views/docs/basics/project-structure.html @@ -18,42 +18,50 @@

Project StructureDirectories

- Vader.js offers relative file paths for easier importing of assets on your webpage and for routing. - Fun fact: the page you are viewing is imported using a relative file path! + Below is how every vader project should be structured!

-

- There are two directories used in Vader for relative paths: /src and - /public. - This allows you to link images or files on your webpage without having to - navigate in and out of folders. - An example: -

- <img src="/images/logo.png"> -
-
- In this case, we only need to reference the /images folder. In Vader, this is changed to - an absolute path: -
-
-
- <img src="https://yourpath/public/images/logo.png"> -
. -

- Vader also handles hash routes for you - this means you can use relative paths inside of a tags to link between pages - without having to worry about whether or not you have included the hash. -

-
-

- Note: you can opt to turn this off simply by adding a comment to your index.html file. - - - <!-- #vader-disable_relative-paths --> - -

- + Every vader root should include these two folders. + src is used for finding relative paths for included page views, public is used in vader to finding + images and fonts for your webpage. +

+ + - **src/*** - Your project source code (components, views, styles, etc.) + - **public/*** - Your public folder (images, fonts, library files) + + + + src/ + + + The + src/ + folder is where most of your project source code lives. This includes: + + + - **components/*** - Your components + - **views/*** - Your views + - **styles/*** - Your styles + - **markdown/*** - Your markdown files -
+ + + public/ + + + The + public/ + folder contains all of your static assets. This includes: + + + - **images/*** - Your images + - **fonts/*** - Your fonts + - **js/*** - Your external imported javascript libraries + + + + +