UNPKG

@graphprotocol/graph-cli

Version:

CLI for building for and deploying to The Graph

17 lines (15 loc) 618 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.generatePlaceholderHandlers = void 0; const generatePlaceholderHandlers = ({ entities, contract, }) => ` import { ExampleEntity } from '../generated/schema' import {${entities.join(', ')}} from '../generated/subgraph-${contract}' import { EntityTrigger } from '@graphprotocol/graph-ts' ${entities .map(entityName => ` export function handle${entityName}(entity: EntityTrigger<${entityName}>): void { // Empty handler for ${entityName} }`) .join('\n')} `; exports.generatePlaceholderHandlers = generatePlaceholderHandlers;