Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

gherkin-ast

2.1.0 • Public • Published

gherkin-ast

Build Status dependency Status devDependency Status

Models for Gherkin feature files

AST

The API provides types to be able to handle different parts of Gherkin feature files.

In TypeScript:

import {Feature, Scenario /*, Background, ... */} from "gherkin-ast";

OR in JavaScript:

const {Feature, Scenario /*, Background, ... */} = require("gherkin-ast");
const feature = new Feature("Feature", "Displaying documents");
feature.elements.push(new Scenario("Scenario", "Opening a document"));
// ...

For detailed documentation see the TypeDocs documentation.

NOTE parse functions only support AST provided by the parser of gherkin@6.

Install

npm i gherkin-ast

DownloadsWeekly Downloads

4,140

Version

2.1.0

License

MIT

Unpacked Size

54.8 kB

Total Files

54

Last publish

Collaborators

  • avatar
  • avatar
  • avatar