Git Product home page Git Product logo

gatsby-starter-theme-workspace's Introduction

Gatsby

Starter for creating a Gatsby Theme workspace

gatsby new my-theme https://github.com/gatsbyjs/gatsby-starter-theme-workspace
cd my-theme
yarn workspace example develop

Layout

.
├── README.md
├── gatsby-theme-minimal
│   ├── README.md
│   ├── gatsby-config.js
│   ├── index.js
│   └── package.json
├── example
│   ├── README.md
│   ├── gatsby-config.js
│   ├── package.json
│   └── src
├── package.json
└── yarn.lock

3 directories, 10 files

gatsby-theme-minimal

This directory is the theme package itself. You should rename this at some point to be gatsby-theme-{my-theme-name}. Also change the package.json name field and the corresponding dependency in the example directory's package.json/gatsby-config.js to match the chosen name.

  • gatsby-theme-minimal/
    • gatsby-config.js: An empty gatsby-config that you can use as a starting point for building functionality into your theme.
    • index.js: Since themes also function as plugins, this is an empty file that gatsby needs to use this theme as a plugin.
    • package.json: The dependencies that your theme will pull in when people install it. gatsby should be a peerDependency.

example

This is an example usage of your theme. It should look the same as the site of someone who installed and used your theme from npm.

  • example/
    • gatsby-config.js: Specifies which theme to use and any other one-off config a site might need.
    • src/: Source code such as one-off pages or components that might live in a user's site.

You can run the example with:

yarn workspace example develop

🚀 Quick start (Gatsby Cloud)

Deploy this starter with one click on Gatsby Cloud:

Deploy to Gatsby Cloud

gatsby-starter-theme-workspace's People

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.