Giter Site home page Giter Site logo

authentication-demo's Introduction

πŸš€ Quick start

  1. Create an Authenticated Site

    In order to get an authentication enabled site up and going follow these steps:

    • Open a terminal of your choice (Terminal on mac, Command Prompt, Powershell or Bash on Windows)

    • Navigate to the directory where you store your repositories

    • Example:

      cd Users/[username]/source
    • Clone the authentication demo

       git clone https://github.com/ethriel3695/authentication-demo
  2. Open the source code and start editing!

    • Open the authentication-demo directory in your code editor of choice

    Add content through mdx

    • Create a content folder
    • Create a post folder
    • Create a folder such as firstPost
    • Create an images folder
    • Add an image in either png, jpg or webp format
    • Create an mdx file firstPost.mdx

    Add content through contentful

    • Create a contentful account https://www.contentful.com/get-started/
    • Select the tab I Build Software and Click Try for free
    • Enter your information and finish the signup process
    • Skip the tutorial and click directly on Add a space
    • Select the Free tier
    • Name your space and create an select Create an empty space and click Proceed to confirmation
    • Click Confirm and create space

    Build out Content model schema for contentful

    Page:

    • Name: Page
    • Api Identifier: Will autopopulate to match Name
    • Description: A short description to describe Content Model
    • Example: Used to specify page types for rendering on the client side (Landing, Post, HeroLanding, etc.)
    • Title: short Text (250 characters)
    • Page Type: Short text (250 characters) - Used to render specific page templates in the code
      • Currently supported page types: (HeroLanding, Landing)
    • Section: One to many sections can be added to a page
    • Slug: Page path for content

    Section:

    • Title: short Text (250 characters)
    • Description: rich text
    • Slug: Page path for section
    • Order: The order that content appears on the page (Ascending)
    • Item: One to many items can be added to a section
    • Image: Media (Not required)

    Item: (Curently only renders as a button)

    Future Functionality: Change to a widget and render content and components dynamically
    • Title: Short Text (250 characters)
    • Sub Header: Short Text (250 characters)
    • Link: External links to other websites
    • Slug: Path to one of the dynamically generated pages (MDX currently)
  1. Start developing.

    Navigate into your new site’s directory and start it up.

    cd authentication-demo &&
    gatsby develop

    Your site is now running at http://localhost:8000!

    Note: You'll also see a second link: http://localhost:8000/___graphql. This is a tool you can use to experiment with querying your data. Learn more about using this tool in the Gatsby tutorial.

🧐 What's inside?

A quick look at the top-level files and directories you'll see in a Gatsby project.

.
β”œβ”€β”€ content
β”œβ”€β”€ node_modules
β”œβ”€β”€ src
β”œβ”€β”€ .gitignore
β”œβ”€β”€ .prettierrc
β”œβ”€β”€ gatsby-config.js
β”œβ”€β”€ LICENSE
β”œβ”€β”€ package-lock.json or yarn.lock
β”œβ”€β”€ package.json
└── README.md
  1. /node_modules: This directory contains all of the modules of code that your project depends on (npm packages) are automatically installed.

  2. /src: This directory will contain all of the code related to what you will see on the front-end of your site (what you see in the browser) such as your site header or a page template. src is a convention for β€œsource code”.

  3. .gitignore: This file tells git which files it should not track / not maintain a version history for.

  4. .prettierrc: This is a configuration file for Prettier. Prettier is a tool to help keep the formatting of your code consistent.

  5. gatsby-config.js: This is the main configuration file for a Gatsby site. This is where you can specify information about your site (metadata) like the site title and description, which Gatsby plugins you’d like to include, etc. (Check out the config docs for more detail).

  6. LICENSE: Gatsby is licensed under the MIT license.

  7. package-lock.json (See package.json below, first). This is an automatically generated file based on the exact versions of your npm dependencies that were installed for your project. (You won’t change this file directly).

  8. package.json: A manifest file for Node.js projects, which includes things like metadata (the project’s name, author, etc). This manifest is how npm knows which packages to install for your project.

  9. README.md: A text file containing useful reference information about your project.

authentication-demo's People

Contributors

ethriel3695 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.