BACK TO DOCUMENTATIONS

Weaver- documentation

TABLE OF CONTENTS



Prerequisites

Before installing and using themes based on the Dega CMS, you need to make sure that your system meets the following requirements:

  1. 1. Node.js Version 18 or Higher
  2. The Dega CMS requires Node.js version 18 or higher to be installed on your system. If you don't have Node.js installed, you can download it from the official Node.js website (https://nodejs.org/en/)

  3. 2. Package Manager (npm or yarn)
  4. You also need to have a package manager installed to install the required dependencies. The recommended package managers are either npm (https://www.npmjs.com/) or yarn (https://yarnpkg.com/).

    To check if Node.js and the package manager are installed on your system, you can run the following commands in your terminal:

    node-v

    This will display the version of Node.js installed on your system. If you see a version number that is less than 18, you need to update your version of Node.js.

    npm-v

    or

    yarn-v

    These commands will display the version of npm or yarn installed on your system. If you don't have either of these package managers installed, you can download and install them from the official npm website (https://www.npmjs.com/) or yarn website (https://yarnpkg.com/)

    Once you have Node.js and the package manager installed, you can proceed to install and use themes based on the Dega CMS.

Theme Installation

  • Installation
  • Configuration

Installation

Once you have the Dega CMS installed and configured, you can download and install a Dega theme to use on your website. Here are the steps to install a Dega theme using npm or yarn:

1. Go to root folder

2. Install the theme using npm or yarn:

with npm:

npm install @factly/gatsby-theme-weaver

with yarn:

yarn add @factly/gatsby-theme-weaver

Configuration

Once you have installed a Dega theme, you may want to configure it to fit your specific needs. Most Dega themes come with configuration options that can be modified to change the look and feel of your website.

1. SPACE ID

This is the ID of the content space that you want to use with your Dega CMS project.

2. ACCESS TOKEN

This is the access token that allows your Dega CMS project to access the content in your space.

3. URI

This is the URI endpoint of your Dega CMS API.


module.exports = {
      plugins: [
        'gatsby-plugin-sass',
          {
           resolve: '@factly/gatsby-theme-weaver',
           options: {
           spaceId: process.env.SPACE_ID,
           accessToken: process.env.ACCESS_TOKEN,
           uri: process.env.API_ENDPOINT,
          },
        },
       ],
      }
     

Theme Shadowing

Theme shadowing in Gatsby allows you to override the default components and styles of a theme with your own custom components and styles.

To get started with theme shadowing in Dega themes, follow these steps:

  • 1. Inside the `src` folder, create a new folder called `gatsby-plugin-theme-ui`.
  • 2. Inside the `gatsby-plugin-theme-ui` folder, create a new file called `index.js`.
  • 3. In the `index.js` file, export a theme object that includes the custom styles and components you want to use. For example:

Please read the guide Shadowing in Gatsby Themes to understand how to customize the theme! Generally speaking you will want to place your files into src/@factly/gatsby-theme-weaver/ to shadow/override files. The Theme UI config can be configured by shadowing its files in src/gatsby-plugin-theme-ui/.

Editing the content

The content of the page is managed by `DegaCMS`.

Changelog

You can find the extensive [changelog of changes on GitHub] (https://github.com/factly/dega-themes/blob/main/themes/gatsby-theme-factly/CHANGELOG.md). You'll be able to see each patch, minor, and major changes and what pull requests contributed to them.

Questions?

If you have general questions or need help with Gatsby, please go to one of the [support platforms](https://www.gatsbyjs.com/contributing/community/#where-to-get-support) mentioned in Gatsby's documentation. If you have a specific question about this theme, you can head to the [GitHub Discussions](https://github.com/LekoArts/gatsby-themes/discussions)


© 2023 Dega Themes

FACTLY is one of the well known Data Journalism/Public Information portals in India. Each news story on FACTLY is backed by factual evidence/data from official sources that is either available in the public domain or that is collated/gathered/collected using tools such as the Right to Information (RTI).