0.2.1 • Published 4 years ago

gatsby-plugin-yaml-i18n v0.2.1

Weekly downloads
9
License
MIT
Repository
github
Last release
4 years ago

gatsby-plugin-yaml-i18n

A YAML-based i18n plugin for gatsby.

This plugin provides an flexible, scalable and developer-friendly approach to i18n in gatsby projects.

Setup

To start from scratch, install the starter project (demo):

gatsby new https://github.com/hitchcott/gatsby-starter-yaml-i18n

To implement in your existing project:

npm i gatsby-plugin-yaml-i18n
module.exports = {
  plugins: [
    {
      resolve: 'gatsby-source-filesystem',
      options: {
        path: `${__dirname}/content`,
        name: 'yaml-i18n-content'
      }
    },
    {
      resolve: 'gatsby-source-filesystem',
      options: {
        path: `${__dirname}/src/templates`,
        name: 'yaml-i18n-templates'
      }
    },
    {
      resolve: 'gatsby-plugin-yaml-i18n',
      options: {
        locales: ['en']
      }
    }
  ]}
}

Examples

Documentation

Detailed documentation is to come. Sorry! See the examples for now.

0.2.1

4 years ago

0.2.0

4 years ago

0.1.5

4 years ago

0.1.4

4 years ago

0.1.3

4 years ago

0.1.2

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago

0.0.1-security

4 years ago