Skip to content

Files

forc-index-ts

forc-index-ts

Example of a forc plugin written in Typescript with Deno runtime.

This plugin simply reads the metadata.indexing.schema_path from the Forc.toml file and displays the logged types.
The code can potentially be extended to process the logged types to index the contract.

Prerequisites

Installation

  1. Clone this repository
  2. Run the following - to globally install the plugin:
cd forc-index-ts/
deno install --global --force --allow-all forc-index.ts

Usage

  1. Check that it was installed:
forc-index --version
  1. Check that forc recognizes the plugin:
forc plugins
  1. Use the plugin with forc:
forc index --path ./sample-project/Forc.toml