Giter Site home page Giter Site logo

substrate's Introduction

Substrate Website

Netlify Status

Content contribution, PRs and merging flow

  • PR providing content (json, md...): open PR against main branch (production)
  • PR providing new features: open PR against main branch (PR builds in netlify staging env)
  • PR providing hotfixes open only against main (PR builds in netlify staging env)

Website Architecture (IA /developers)

image

Development

Install

Navigate into your cloned local repo directory and install all dependencies.

yarn

Configure environment variables

Copy example.env.development and rename to .env.development

Config URL variables based on your preferable local setup. URL will be used for links generation between Substrate websites.

Default localhost port configuration:

GATSBY_WEBSITE_URL=http://localhost:8100
GATSBY_DOCS_URL=http://localhost:8200
GATSBY_MARKETPLACE_URL=http://localhost:8300

Start development server

Navigate into your new site’s directory and use the following command to start the development server locally.

yarn develop

Setup, configuration & plugins

i18n (bypassed)

Docs:

Configuration

You can find the config for i18n, using i18next with gatsby-plugin-react-i18next.

  • the markdown content is located in ./content/{language}/{content_type}/*/
  • the language strings are located in ./locales/{language}/{data_type}.json

The default language (and fallback language) is en for english.

Extract strings

To extract the strings that needs to be translated, it is possible to run yarn extract-locales, which will generate the /locales-tmp folder.

netlify-cms (bypassed)

netlify-cms-app & gatsby-plugin-netlify-cms are used to setup [netlify-cms](https://www.netlifycms.org) for this project.

The gatsby gatsby-config pluggin, points to the file src/cms/index.js, as entry file of the configuration.

local git-gateway backend

To develop and use netlify-cms with the data available in the local repository folder:

In the file ./.env.development set:

GATSBY_NETLIFY_CMS_GIT_LOCAL=true

Then in the project's root folder run:

npx netlify-cms-proxy-server

and in an other shell and the same folder, run the development server as usual.

Adding, updating and removing content from Ecosystem Projects

Substrate projects can be added, updated, or removed by updating the markdown files located at content/en/projects.

To add a new project please add a new markdown file in this folder that follows the naming convention already in place.

To remove a project please remove the appropriate markdown file in content/en/projects.

The same editing is available for project types and project categories the markdown for these fields lives in content/en/project-types and content/en/project-categories respectively. Please use the current markdown structure as a template and guide.

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.